Let\'s say I have a Python script yieldtest.py using a generator function:
yieldtest.py
def yieldfunc(): yield 2 yield 4 yield 8 yield 16 def