© Beau Nouvelle 2019
Beau NouvelleSimulations in Swift 5https://doi.org/10.1007/978-1-4842-5337-3_7

7. Game of Life

Beau Nouvelle
Victoria, Australia
Developed by John Conway in 1970, the Game of Life is a cellular-automaton, zero-player game. A game in the lightest sense as there is no user interaction beyond the initial starting conditions and neither is there an end.
The game takes place on a grid of cells. Each cell can either be alive or dead. Four simple rules govern the vitality of each cell.
  1. 1.
    Any live cell with fewer than two live neighbors will die.
  2. 2.
    Any live cell with two or three live neighbors will live on to the next generation.
  3. 3.
    Any live cell with more than three live neighbors will die.
  4. 4.
    Any dead cell with exactly three live ...

Get Simulations in Swift 5: Design and Implement with Swift Playgrounds now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.