I was looking for the JS equivalent of
[0]*n for creating an array(lists in python) of n length. How do I do that using the Javascript?
I was looking for the JS equivalent of
[0]*n for creating an array(lists in python) of n length. How do I do that using the Javascript?
//12 is an axample, the length of the array
let arr = new Array(12).fill(0);
console.log(arr)