On 01/03/2015 06:10 PM, WolfRage wrote:
On 01/03/2015 04:42 PM, Dave Angel wrote:
self.transposed_grid = list( zip(*self.grid) )
This results in the same thing with or with out the list() wrapper. Using
Python 3.4.0 (default, Apr 11 2014, 13:05:11)
[GCC 4.8.2] on linux

In Python 3, zip() returns an iterator. So you can traverse it once. I don't believe the second time is guaranteed to be the same. A list is what you want.


--
DaveA
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Reply via email to