The only way to find the genome of a cell at a given location (a very common task) is to manually search through all cell.x and cell.y. We need a better way to do this. Sorting is an option, and so is creating a 2d array, but the easiest way would be to make the cells list a dict, and create a location string as the key. Thus one can just do cells['x,y'] or similar.
The only way to find the genome of a cell at a given location (a very common task) is to manually search through all cell.x and cell.y. We need a better way to do this. Sorting is an option, and so is creating a 2d array, but the easiest way would be to make the cells list a dict, and create a location string as the key. Thus one can just do cells['x,y'] or similar.