|
Programming Guru
Join Date: Apr 2005
Location: Waterloo, Ontario
Posts: 1,888
Rep Power: 5 
|
Re: Conway's Game Of Life - Programming Challenge
Hehe. Amusing huh?
Quite a fascinating game. Probably the most interesting game that you can't "play".
One thing you might want to think about adding is a test to see if all the cells are dead. If they are, then stop, and output how many generations the cells survived for.
Edit:
And while we're on the topic, here is one I invented. I like to call it "Napalm". This little devil explodes quite spectacularly out from the center, and then continues to emit small explosions, until eventually settling and leaving behind two small craters in the middle. Run at maximum speed for full effect.
Copyright Sane.
char inpGen[ROWS][COLS] = {
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000001000000000000000000000000000000000"},
{"00000000000000000000000010100000000000000000000000000000000"},
{"00000000000000000000000100010000000000000000000000000000000"},
{"00000000000000000000000100010000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"},
{"00000000000000000000000000000000000000000000000000000000000"}
};
|