题目: function template(tmpl, data) { // your code } template('我的名字是{ {name}},我的工作是{ {work}},我喜欢{ {work}}', { name: '小周', work: '编程' }); // 函数的返回是 '我的名字是小周,我的工作是编程,我喜欢编程' 解法1:使用正则表达式以及replace function template(tmpl,data){ let str = tmpl.