tracks/vendor/plugins/rspec/examples/stories/game-of-life
2008-06-19 10:13:59 +02:00
..
behaviour merge upstream changes 2008-06-19 10:13:59 +02:00
life Added Rspec and Webrat plugins and started porting Selenium on Rails tests to Rspec Plain Text Stories driving Webrat driving Selenium. 2008-06-18 02:57:57 -04:00
.loadpath Added Rspec and Webrat plugins and started porting Selenium on Rails tests to Rspec Plain Text Stories driving Webrat driving Selenium. 2008-06-18 02:57:57 -04:00
life.rb Added Rspec and Webrat plugins and started porting Selenium on Rails tests to Rspec Plain Text Stories driving Webrat driving Selenium. 2008-06-18 02:57:57 -04:00
README.txt Added Rspec and Webrat plugins and started porting Selenium on Rails tests to Rspec Plain Text Stories driving Webrat driving Selenium. 2008-06-18 02:57:57 -04:00

John Conway's Game of Life

The Rules
---------
The Game of Life was invented by John Conway (as you might have gathered).
The game is played on a field of cells, each of which has eight neighbors (adjacent cells).
A cell is either occupied (by an organism) or not.
The rules for deriving a generation from the previous one are these:

Survival
--------
If an occupied cell has 2 or 3 neighbors, the organism survives to the next generation.

Death
-----
If an occupied cell has 0, 1, 4, 5, 6, 7, or 8 occupied neighbors, the organism dies
(0, 1: of loneliness; 4 thru 8: of overcrowding).

Birth
-----
If an unoccupied cell has 3 occupied neighbors, it becomes occupied.