I am initializing my 2D array using the below snippet:
let arr = new Array(m).fill().map(() => new Array(n).fill(-1)); <