Other Iteration Topics

As mentioned in this chapter’s introduction, there is more coverage of both list comprehensions and iterables in Chapter 20, in conjunction with functions, and again in Chapter 30 when we study classes. As you’ll see later:

In particular, user-defined iterables defined with classes allow arbitrary objects and operations to be used in any of the iteration contexts we’ve met in this chapter. By supporting just a single operation—iteration—objects may be used in a wide variety of contexts and tools.