Lesson 3: Where names live, and functions as values
15 min read·14 Oct 2026
Module 6 · Lesson 3 · About 45 minutes · Needs: Module 6 Lessons 1 and 2 (def,return, parameters), Module 5 (lists, dictionaries, comprehensions)
The situation
Amira likes the functions from Lessons 1 and 2: days_late(21, 44) says Ben is 9 days late every time. Now she wants the overdue loans in order, most owed first, so she knows whom to call. And she wants proof that the fee rule is right before it touches the charity jar.
That needs three ideas: which names a function can see, how to hand one function to another, and how to check a function in one line.