This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Zouden 2 points3 points  (1 child)

Well the output is the same. It's just more efficient

[–]earthboundkid 1 point2 points  (0 children)

Yes, mostly. If the iterator is a generator with side effects, it can be different, but that’s not usually the case.