forEach用法:

var array1=[1,2,3];
array1.forEach(function(item,index){
console.log(item+'---'+index);
});

node.js之forEach-LMLPHP

05-16 05:14