Quote Originally Posted by C_ntua View Post
How big is the array? I don't know why you use a 3d array in the first place.
Generally you could make the 3d array in a 2d array, even if 1d array, but how would that help? The point is to reduce the total information needed.

My first thought is that the board game Game of Life cannot run slow in any possible implementation. It is a simple turn based game.
So:
1) How big is the 3d array? And why is it 3d?
2) Give some code (if you want) of the function you think delays the game
it has to be a cube with tha n*n*n dimensions with n*n*n cells . i tested it with n = 64 and 5 generations , and even with one generation it doesn't stop from running . with n = 10 it's ok


for(i=0;i<max;i++)
for(j=0;j<max;j++)
for(k=0;k<max;k++){

another 3 for cycles for the area in witch the neighbours are

test if the neighbour matrix[i'][j'][k'] of the element matrix[i][j][k] is alive



do u know a way to transform a 3d matrix in a 2d one