Simon Willison’s Weblog

Subscribe

Origin of “list comprehension”

17th June 2003

Via Jarno Virtanen, a comp.lang.python post explaining the origin of the term “list comprehension”, Python’s clever alternative syntax for filtering lists (see this chapter of Dive Into Python). The term comes from set theory; it’s nice to know that stuff was worth learning after all ;)

This is Origin of “list comprehension” by Simon Willison, posted on 17th June 2003.

Next: IRC on your mobile

Previous: Python generators for database result sets

Previously hosted at http://simon.incutio.com/archive/2003/06/17/setTheory