i want to make a 2d minecraft like game and have a random terrain generation using arrays
Develop games in your browser. Powerful, performant & highly capable.
there are a great number of examples of this already, search the page.