Skip to main content Link Search Menu Expand Document (external link)

Loops and Variables

Readings

The readings for this week cover three topics. First, we will learn a bit more about strings and about the print() function, which outputs strings. We’ve been using both in class already. Second, we’ll learn about two kinds of loops – while loops and for loops. And third, we’ll learn a bit about using random numbers in Python.

Strings and Print()

Loops

Randomness

Summary

For the summary this week, focus on loops and randomness. Think about similar things you have encountered before.

Summary prompt: How would you describe loops and randomness in your own words, and what do you think each thing might be used for in programs?

Question

As per usual, your question can be one of three types:

  • Confusion: what didn’t you understand in the readings?
  • Curiousity: what do you want to know more about?
  • Connection: how does this topic connect to your own experiences?

Submit your summary+question on D2L under Quizzes before class starts on Tuesday.