List comprehension confusion...

Andrew Bennetts andrew-pythonlist at puzzling.org
Sat Feb 1 22:39:58 EST 2003


On Sun, Feb 02, 2003 at 03:10:27AM +0000, Afanasiy wrote:
> I am confused about the purpose of list comprehensions.
> What can they do which an explicit for loop cannot?

They can be used in an expression.

-Andrew.






More information about the Python-list mailing list