JavaScript fill()
method fills method put a static value on each index of array.
JavaScript fil() method Syntax
fill(value)
fill(value, start)
fill(value, start, end)
here is the example of javascript fill method
const arr = [6];
arr.fill(0);