← All problems
Game of Life (in-place)
Compute the next state of Conway's Game of Life on a grid in place: each cell's next state depends on its eight neighbors' current states, so the update must not clobber data still needed.
Complexity
Time O(mn), Space O(1)
Common pitfalls
- Extra board (violates in-place)
- Counting transitional states as live/dead wrong
Your solution
Log in to save your code and track progress.