When representing worlds, you normally save a set of objects. The programm will iterate over the objects or tuples of objects very often, so it's necessary to minimize the work. It should also not consume unneccessary memory. There a several ways to represent these sets of objects.
The simplest way is just an array of objects. This will require all objects to be the same size. It's also possible to let the objects contain references to other data.