Implementation of Conway's Game of Life in an infinite space in Swift. Alive cells are stored in a set. To calculate the next iteration, we compute the number of neighbors for each cell that has neighbors.
I am implementing the Game of Life in different programming languages to learn about them. You can find all of my implementations on GitHub.
swift run