The Python Oracle

Understanding generators in Python

Become part of the top 3% of the developers by applying to Toptal https://topt.al/25cXVn

--

Music by Eric Matyas
https://www.soundimage.org
Track title: Hypnotic Orient Looping

--

Chapters
00:00 Question
00:45 Accepted answer (Score 442)
05:05 Answer 2 (Score 54)
06:26 Answer 3 (Score 32)
07:19 Answer 4 (Score 23)
08:24 Thank you

--

Full question
https://stackoverflow.com/questions/1756...

Accepted answer links:
[generator]: http://www.python.org/dev/peps/pep-0255/
[next]: http://docs.python.org/3/library/functio...
[generator expressions]: http://www.python.org/dev/peps/pep-0289/
[list comprehensions]: http://docs.python.org/3/tutorial/datast...
[reference]: http://docs.python.org/3/reference/expre...
[Fibonacci numbers]: http://en.wikipedia.org/wiki/Fibonacci_n...
[itertools.islice]: http://docs.python.org/3/library/itertoo...
[itertools]: http://docs.python.org/3/library/itertoo...

Answer 3 links:
[here]: http://docs.python.org/library/stdtypes....
[the glossary entry for ]: http://docs.python.org/glossary.html#ter...

--

Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...

--

Tags
#python #generator

#avk47