。
var arr = Object.keys(Array.apply(null, {length:100})) console.log(arr);
var arr = Object.keys(Array.apply(null, {length:100})).map(function(item){ return +item; }); console.log(arr);
var arr = Array.from({length:100}, (v,k) => k); console.log(arr);
var arr = new Array(100).keys(); console.log(Array.from(arr));
var arr = Object.keys(Array.from({length:100})); console.log(arr);
var arr = Object.keys(Array.from({length:100})).map(function(item){ return +item; }); console.log(arr);
var arr = [...Array(100).keys()]; console.log(arr);
var arr = [...Array.from({length:100}).keys()]; console.log(arr);
var arr = Object.keys(String(Array(101))); console.log(arr);
var arr = Object.keys(String(Array(100))).map(function(item){ return +item; }); console.log(arr);
var arr = Object.keys(new Int8Array(100)).map(function(item){ return +item; }); console.log(arr);
var arr = []; var i = 0; var timer = setInterval(function(){ arr[i] = i++; if(i>=100){ clearInterval(timer); console.log(arr); } },1);
var arr = []; var i = 0; function MakeArray(num){ if(i<num){ arr[i] = i++; MakeArray(num); } return arr; } console.log(MakeArray(100));
var arr = new Array(100).toString().split(',').map(function(item,index){ return index; }); console.log(arr);
。