fork download
  1. a = [1,2,3]
  2. i = iter(a)
  3. print(next(i))
  4. print(next(i))
  5. print(next(i))
  6. print(next(i))
  7.  
Runtime error #stdin #stdout #stderr 0.12s 23408KB
stdin
Standard input is empty
stdout
1
2
3
stderr
Traceback (most recent call last):
  File "./prog.py", line 6, in <module>
StopIteration