var?hundred?=?new?Array(100).join("").split(",").map(function(item,index){
????????????????????return?index;
????????????????});
????????????????hundred.forEach(function(item,i){
????????????????????return?console.log(item);
????????????????})創(chuàng)建一個索引與值相同的0到100的數(shù)組,但是join("")里面不加逗號就不行,不是默認(rèn)為逗號?
有點打腦殼呢
西蘭花偉大炮
2017-04-25 13:59:45