Back to curriculum

Week 2

Week 2: Loops, Strings, and Lists

Combine loops with strings and lists so students can process repeated and sequence-based input.

Log in to track progress on the assigned problems.

Week 2: Loops, Strings, and Lists

Students trace loops, build accumulators, and solve problems with strings and lists.

Topics

  • for loops and while loops
  • range()
  • counters and accumulators
  • list indexing and iteration
  • string cleanup and transformations

Required Problems

  • Module Countdown
  • Badge List
  • Clean Project Title
  • Count Vowels
  • List Maximum

Lesson completion is automatic. Students complete the week when every required problem has an accepted submission.

Required practice

Problems for this lesson

Solve all assigned problems to complete the week.

1LoopsBeginner

Module Countdown

Before a demo, a mentor counts down from `n` to 1. Print each number on its own line.

Open problem
2ListsBeginner

Badge List

Each student has earned practice badges. Given badge counts, print the largest count.

Open problem
3StringsBeginner

Clean Project Title

For a project URL preview, convert a project title to lowercase letters.

Open problem
4StringsBeginner

Count Vowels

Count how many vowels appear in a line of text. Treat uppercase and lowercase vowels the same.

Open problem
5ListsBeginner

List Maximum

Find the largest integer in a list.

Open problem