Week 6: Control Flow and Iteration
In lecture, professor Ayazifar taught you about control flow and iteration, well known as conditionals/if-statements and for loops. Conditionals allow us to make our programming more generalizable. Based on a certain value, we can output a different value or perform different operations. For loops are to allow us to do the same thing, but then for multiple things. It creats the infrastructure for us to iterate over each item in an iterable (in Data 8, you can just think of this as a list.) in as few as 2 lines.
Discussion
Worksheet Slides Slides Annotated Solutions
Lab
Corresponding Readings
Those readings are not required or necessary. However, if you feel that you want to brush up before coming to section or feel iffy about certain topics after discussion, you are encouraged to go through the readings.