Paul:
enum WORLDSIZE = 20;
enum INITIALPOP = 70; //experimental
enum DEAD = 0;
enum ALIVE = 1;
D enums don't need to be ALL UPPERCASE :-)
int world[WORLDSIZE][WORLDSIZE];
Don't forget to compile with warnings active (it's a design error of the D compiler to have them disabled by default).
foreach(i; 0..INITIALPOP){
It's less bug-prone to make that index immutable:
foreach(immutable i; 0 .. initialPop) {
Bye,
bearophile
