The Secret of LIFE
by ?
from ZX Computing, October 1982 page 97

The Secret of LIFE

We set you a problem, and show one way to solve it.

The game of LIFE was invented by John Conway of Cambridge
University in October, 1970. It simulates the birth, death and
growth of cells in a closed colony.

   Before the state of a cell for the 'next generation' (a
generation is a complete check, and reprint of the grid upon which the
colony lives) is determined, it must be compared with the eight
surrounding cells. if there are two or three occupied cells around the
one being checked, and the one being checked is occupied, there
is no change; it survives till the next generation. If there are three
and only three occupied cells. and the cell being checked is empty, a
cell is 'born' there in the next generation. If there are four or
more neighbours, the cell being checked 'dies', that is, is emptied
in the next generation.

   That is almost all the information you need to construct a game
of LIFE from first principles. There is just one more thing - the rules
are applied all over the grid at once. So you need one array to hold
the current generation, and another to hold the new generation, so that
changes for the next generation do not effect cells which have not yet
been checked in the present generation. Set up a 10x10 grid, and try
and work out a program to (a) place some cells on it; (b) check each of
these cells in turn in accord with Conway's laws, and then update a
reference array; (c) copy the reference array into a 'print out' array;
and (d) print out the colony and start again.

Here's one way of doing it, which uses two 'data' statements in the
form of strings which are accessed element by element. A$ in line 30
contains information regarding the numerical relationship of cells to
each other (eg + 1 is one to the right, -1 is one to the left and soon).
A$ in line 90 is the position of the starting cells, when the grid is
numbered one to 100.

Other starting colonies you can try:

BEEHIVE:	45, 45, 46, 64, 65, 66, 74, 76, 85

CROSS:		43, 47, 54, 56, 65, 74, 76, 83, 87

MOBIUS:		23, 24, 25, 33, 34, 36, 43, 44, 45, 56, 57, 53, 66, 67,
		68, 76, 77, 78

RUSSLAN:	33, 34, 35, 36, 37, 38, 47, 56, 65, 74, 83, 34, 85,
		86, 87, 83

FLAME:		18, 26, 38, 46, 51, 52, 53, 54, 55, 56, 57, 58, 59, 36,
		76, 86, 96
