This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author steven.daprano
Recipients Vishu Viswanathan, ronaldoussoren, serhiy.storchaka, steven.daprano
Date 2017-12-07.14:33:16
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1512657196.66.0.213398074469.issue32242@psf.upfronthosting.co.za>
In-reply-to
Content
I decided to run the code in 3.5 and 2.7, and now that I know what I'm looking for, I can see the results buried in the Anaconda notebook.

This is not a bug, zip has been changed in Python 3 to return an iterator instead of a list. To get the same results as Python 2.7, change the line:

z = zip(j, k)

to:

z = list(zip(j, k))

To get the same results in 2.7 as in 3, change it to:

z = iter(zip(j, k))

This is documented and is not a bug.

https://docs.python.org/3.0/whatsnew/3.0.html#views-and-iterators-instead-of-lists

https://docs.python.org/3/library/functions.html#zip
History
Date User Action Args
2017-12-07 14:33:16steven.dapranosetrecipients: + steven.daprano, ronaldoussoren, serhiy.storchaka, Vishu Viswanathan
2017-12-07 14:33:16steven.dapranosetmessageid: <1512657196.66.0.213398074469.issue32242@psf.upfronthosting.co.za>
2017-12-07 14:33:16steven.dapranolinkissue32242 messages
2017-12-07 14:33:16steven.dapranocreate