var c=['name','age','city']; var d=['xiaogang','12','anhui']; var a={}; for(var i=0;i<3;i++){ a[c[i]]=d[i]; } console.log(a); //返回 {name: "xiaogang", age: "12", city: "anhui"}