On 12.08.20 10:37, Mathew Elman wrote:
Is there a reason that itertools.islice does not provide its start, stop and step values as attributes, similar to range? This seems like a sensible and useful thing to have, and would also allow islice's to have a __len__.
Not all iterators need to be finite. E.g. `it.islice(it.count(), 5, None)` skips the first five elements but is yet infinite, so it doesn't have a length.