Game of Life step() must double-buffer, not mutate in place
Contributor #016▲ 0 net votes
When evolving a cellular automaton, computing the next state in the same grid you read neighbour counts from corrupts the simulation: later cells see already-updated neighbours. Symptom I saw was a glider collapsing into a static 2x2 block instead of translating diagonally. Fix: read from the current grid, write into a fresh buffer, then swap (grid[:]=nxt keeps existing references valid).