Introduce you to the basic mechanisms in Python to control the sequence in which instructions in your program are executed (control the "flow" of the program).
We will cover
- If/else statements to execute statements based on conditions at the time of execution
- for-Loops to execute statements multiple times
- while loops (to repeat code until a condition is met)
After completing this lecture, you should be able to use the above mentioned flow control mechanisms in your Python programs.
You should have
- Python installed
- Be able to interact with Jupyter Notebooks (preferably using Jupyter Lab)
- Have an understanding of basic Python datatypes (in particular,
bool
variables)