Lesson 9: Making decisions
Outline:
- Recap Lesson 8
- Functions and variable scope
- Making choices
- Boolean expressions in Python
- Exercise 3
- Two-way decisions:
if
/else
- Exercise 4
Explore after class:
- Practice with functions:
- functions that return multiple values: Exercise 5
- functions that modify their parameters: Exercise 6
- Error handling with conditional code: Exercise 7
Reading assignment (to be completed by the next class):
- Zelle sections 6.6-6.8 (pp. 193-203)
- Zelle sections 7.1-7.2 (pp. 209-220)
- Assignment #4 (due next Thursday at 10pm)