A program must make decisions, so that the instructions executed vary depending on the data input to the program. This session introduces:
- Condition or ‘if’ statements in Python
- Boolean (or logical) expressions, which are used in programs (and also in the design of computers themselves).
Course Materials
| Practical Sheet 3 |
| Practical Sheet 3 |
Slides Set 1
| Powerpoint | |
| 3.1 If Statements in Python | 3.1 If Statements in Python |
| 3.2 Dry Run a Program | 3.2 Dry Run a Program |
| 3.3 Boolean Logic and Truth Rules | 3.3 Boolean Logic and Truth Rules |
Test Papers
| Test Sheet 3 |
| Test Sheet 3 |
Other Resources
| Jack’s Tell Me a Story Project |
| Jack’s Tell Me a Story Project |