21 Apr
2020
21 Apr
'20
12:44 a.m.
Alex Hall wrote:
Surely no exception is raised because zip is lazy?
Ack, you're right. The same problem would come up wherever you actually _use_ the zip, of course, but it's harder to demonstrate and reason about. So change that toy example to `zipped = list(zip(x, y, strict=True))`. (Fortunately, it looks like Ram got what I intended despite my mistake.)
Doesn't it still have to be even with strict=True?
Well, I suppose technically it doesn't _have_ to be, but it certainly _should_ be. (Although it's a bit weird to say "it should be lazy even with `strict=True`" out loud; maybe that's a mild argument for using a different qualifier like `equal`, as in more-itertools?)