The rules for each successive generation of Conway's Game of Life is to count the number of neighbouring cells to determine what the new state of a cell is. The new state is:
- empty; if there are less than two neighbours or more than three neighbours
- occupied; if there are three neighbours
- unchanged from the previous generation; if there are two neighbours