7. Functional List Processing¶
In this chapter, we will take a look at the functional approach to processing sequences of data. We start by definition three general types of sequence processing tasks. Then we look at the Python function in more depth, followed by defining data structures and functions recursively. Next, tail recursion is used to improve some recursive tasks using an accumulator. Finally, we compare solutions based on list comprehensions to those that use recursion.
- 7.1. More Details About Python Functions
- 7.2. Python Functional Parameters
- 7.3. Three General Tasks
- 7.4. What are Higher Order Functions?
- 7.5. Other Examples of Higher Order Functions
- 7.6. Common Patterns for Processing Sequences with Dictionaries
- 7.7. Lazy Iteration
- 7.8. Working with Large Files
- 7.9. Exercises