What does the "yield" keyword do in Python?

pythongeneratorsiterablesyielditertools

Abstraction: Python yield keyword creates generator objects lazily

Key points:

Connections: Python · Generators · Lazy Evaluation · Iterators

Source: http://stackoverflow.com/questions/231767/the-python-yield-keyword-explained