https://www.reddit.com/r/csharp/comments/wpw11f/how_often_are_multidimensional_arrays_and_jagged/
Making grids for maps
Depends on what you want. If you have a small world (like less than a few thousand tiles), a 2D array is fine. If you have a large/infinite world, like terraria, a good approach is to split the world into chunks (a bunch of 2D arrays) and store them in a dictionary, where the key is the coordinate of the chunk. This has a few advantages: you don’t have to know the size of the world beforehand your world doesn’t have to be rectangular you can easily load/unload chunks from wherever it’s relatively fast and simple However, it is a bit slower and complex than using a single 2D array if your world is small, so both are good approaches depending on the project.
A single dimensional array is superior to jagged and multidimensional; which is slower one way or another which is the opposite of what we want in games.
You can "create" a grid by making the length MaxX * MaxY and access X, Y using X * MaxX + Y.
https://www.rockpapershotgun.com/how-do-roguelikes-generate-levels