Understand these generators!

At this point you should spend some time exploring these two generators before moving on. Make sure you understand how they work and how control flows in and out of them as they maintain state. If you're using an IDE to run these example, you can use the debugger to follow control flow by putting breakpoints in the generators and in the code that uses them. You can accomplish the same by using Python's built-in pdb debugger (which we cover later) or even just by using old-fashioned print statements.

However you do it, make sure you're really comfortable with how these generators
work before moving to the next sections.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset