3 ms·
You should be able to create an unbounded for loop as well. After all, a python process has mutable state, so it should be fairly simple to increment the length
by choeger 5y ago
You should be able to create an unbounded for loop as well. After all, a python process has mutable state, so it should be fairly simple to increment the length of your loop inside the loop body.
- uryga 5y ago>>> x = [0] >>> for x in xs: ... print(x) ... xs.append(x+1)