📅  最后修改于: 2022-03-11 15:03:05.004000             🧑  作者: Mango
function count(n){
var res = []
for (var x = 0; x < n; x++) {
res.push(x)
}
return res
}
for (var x of count(5)) {
console.log(x)
}