[Python 2.7.3] What's the difference between these two uses of "for"?

Yves S. Garret yoursurrogategod at gmail.com
Mon Mar 18 01:58:19 CET 2013


N00b question.  But here is the code:

http://bin.cakephp.org/view/709201806

In the first example, the first for-loop is run and then the list is assigned to the tricky variable.  But, what 
happens in the second example?  Does the loop after "in" get run only once or multiple number of times?



More information about the Python-list mailing list