Game of life solution