The Python Oracle

Is any() evaluated lazily?

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: Puzzling Curiosities

--

Chapters
00:00 Question
00:56 Accepted answer (Score 20)
01:43 Answer 2 (Score 16)
02:13 Answer 3 (Score 9)
02:53 Answer 4 (Score 2)
03:21 Thank you

--

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

Accepted answer links:
[docs]: https://docs.python.org/3/library/functi...

Answer 2 links:
[all()]: https://docs.python.org/2.7/library/func...
[any()]: https://docs.python.org/2.7/library/func...

Answer 3 links:
[generators]: https://stackoverflow.com/questions/4778...
[expressions]: https://www.python.org/dev/peps/pep-0289/
[functions]: https://www.python.org/dev/peps/pep-0255/
[iterators]: https://docs.python.org/3/tutorial/class...

--

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

--

Tags
#python

#avk47