Skip to content

Instantly share code, notes, and snippets.

@alexDeCastroAtGit
alexDeCastroAtGit / game-of-life.py
Created November 19, 2017 18:01 — forked from mickeypash/game-of-life.py
Conway's Really Simple Game of Life based on ("Stop Writing Classes" PyCon 2012)[https://www.youtube.com/watch?v=o9pEzgHorH0]
import itertools
# Conway's Really Simple Game of Life based on "Stop Writing Classes" PyCon 2012
def neighbors(point):
x,y = point
yield x + 1, y
yield x - 1, y
yield x, y + 1
yield x, y - 1