const keys = ['zhangsan','lisi','wangwu'] const nums = [18,36,56] const obj = keys.reduce((obj,item,index)=>{ console.log(JSON.stringify(obj),item,index) obj[item] = item return obj },{}) console.log(JSON.stringify(obj))