Chapter 4
Algorithms and Data Structures
Section 6
Level 4 - Problem 5
Write a program that implements the Game of Life cellular automaton proposed by John Horton Conway. The universe of this game is a grid of square cells that could have one of two states: dead or alive. Every cell interacts with its adjacent neighbors, with the following transactions occurring on every step: - Any live cell with fewer than two live neighbors dies, as if caused by under population - Any live cell with two or three live neighbors lives on to the next generation - Any live cell with more than three live neighbors dies, as if by overpopulation - Any dead cell with exactly three live neighbors becomes a live cell, as if by reproduction - The status of the game on each iteration should be displayed on the console, and for convenience, you should pick a reasonable size, such as 20 rows x 50 columns.