On 04/01/2016 03:26 PM, Steven D'Aprano wrote:
Incorrect. range is a lazy sequence.
But how does range "know" that it has to start from scratch again? As in this example:
it = range(10) for i in it: if i >= 3: break for i in it: # why does it start from zero again? print(i) -- https://mail.python.org/mailman/listinfo/python-list