-4

Hello:
My problem is:

"The game of Life takes place on a 2d array of cells, each of which may contain an organism. Let occ(i) be the no. of cells adjacent to cell i that are occupied by an organism is obtained from the previous generation appling the following rules:
1.An organism in cell i survive to the next generation if 2<=occ(i)<=3 otherwise it dies.
2.An organism born in emty cell i if 2<=occ(i)<=3 otherwise it remains empty.
Write a program that reads initial configuration of occupied cells and print a series of generation. Note that the program of must maintain two copies of the configuration. Since all changes occur simultaneously."

Plz give me the code of this game.

3
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by mvmalderen
0

>Help me in Game of Life
Life's not a game, you have to live on your own, the same goes for your programs: you have to write them yourself.
Come back when you've something to show us.

Edited by mvmalderen: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.