pgbovine/OnlinePythonTutor — Issue #7: yield and ASSERTION ERROR
Author: myroslav
Created: 2012-03-09 22:02:17+00:00
State: open

When stepping through this program, on second iteration of for loop when entering iterator Tutor starts displaying ASSERTIOn ERRORs, but continues to work properly:

```python
def fibonacci():
a, b = 1, 2
while True:
yield a
a, b = b, a+b

f = fibonacci()
for i in range(10):
print f.next()
```