Implementation of Conway's Game of Life in an infinite space in Python. Alive cells are stored in a set. To calculate the next iteration, we compute the number of neighbors for each cell that has neighbors.
Peter Norvig has a fantastic explanation in a Jupyter Notebook.
My goal was to write a pythonic program that is easy to understand (limit the use of comprehensions).
I am implementing the Game of Life in different programming languages to learn about them. You can find all of my implementations on GitHub.
python game_of_life.py
Run python test.py
.
Check out this sonification of the output of this program: https://github.com/Mystified131/GameOfMusic.