GameOfLife base code