Skip to content

References: Collections, Control Flow, Functions, and Error Handling

  1. Control flow - Wikipedia - Explains conditionals, loops, and branching that decide the order statements run. Directly supports this chapter's coverage of if statements and for/while loops.

  2. Subroutine - Wikipedia - Describes functions, parameters, return values, and why they make code reusable. Reinforces the chapter's introduction to defining and calling functions.

  3. Exception handling - Wikipedia - Covers how programs detect and recover from errors at runtime. Provides background for the chapter's try/except error-handling section.

  4. Python Crash Course (3rd Edition) - Eric Matthes - No Starch Press - Chapters 3–8 walk through lists, dictionaries, if statements, loops, and functions with beginner-friendly projects that match this chapter's scope.

  5. Automate the Boring Stuff with Python (2nd Edition) - Al Sweigart - No Starch Press - Clear chapters on flow control, functions, and lists with practical exercises that help students cement the concepts in this chapter.

  6. More Control Flow Tools - Python Software Foundation - The official tutorial on if, for, while, and defining functions. Authoritative reference for the chapter's core topics.

  7. Python Lists and Tuples - Real Python - Detailed tutorial on creating, indexing, and modifying collections. Expands on the chapter's coverage of lists and other collection types.

  8. Python Functions - W3Schools - Concise reference with a try-it editor for arguments, return values, and defaults. Handy while working the chapter's function exercises.

  9. Python Exception Handling - GeeksforGeeks - Explains try, except, else, and finally with examples. Reinforces the chapter's error-handling section with extra practice.

  10. Dictionaries in Python - Real Python - Thorough guide to key-value collections, a tool used throughout later sensor and display projects. Builds on the chapter's introduction to dictionaries.