[Class Report] Introduction to System Development – Week 4: “Repetition” Is What Computers Do Best
We’ve reached Week 4 of our system development class. This week’s theme was “repetition (loop processing).” We learned how to give instructions to a computer—an expert at doing the same thing over and over—about how many times and how to repeat a task.
■ Introduction of the Day: “Humans Get Bored, but Computers Don’t”
Mr. Tanaka: “If someone asked you to count from 1 to 10, you could do it in about 10 seconds, right? But what if they asked you to do that 100 times?”
Student A: “No way. I’d get bored halfway through. (laughs)”
Student B: “A computer could probably handle that no problem.”
Mr. Tanaka continued:
Mr. Tanaka: “Exactly. Loop processing is one of a computer’s greatest strengths. Today, we’ll learn how to give it those instructions.”
■ Exercise ①: Count Numbers with a for
Loop
We started with a simple task: display the numbers 1 through 5.
for i in range(1, 6):
print(i)
Mr. Tanaka: “range(1, 6)
means ‘from 1 to 5’. In Python, the end value (6) is not included—keep that in mind.”
Student C: “Hey, does the variable have to be called i
?”
Mr. Tanaka: “Good question! i
is a common convention, but you can use any name that makes sense to you.”
■ Exercise ②: Use while
Loops for Conditional Repetition
Next, we tackled the while
loop, which repeats “as long as a condition is met.”
x = 1
while x <= 5:
print(x)
x += 1
Mr. Tanaka: “Here, it means ‘repeat while x is less than or equal to 5’.”
Student D: “So if the condition isn’t met, it doesn’t run at all?”
Mr. Tanaka: “Exactly! That’s one key difference from for
loops.”
■ Focus Time: Create Your Own Original Loop
Today’s mini challenge was to “create a loop of your choice.” Students brainstormed ideas and created unique loops of their own.
💡 Student Ideas
- A program that displays the multiplication table (like 1×1 to 9×9)
- Displaying “Fizz” only for multiples of 3
- A 10-second countdown timer
Student E: “It’s starting to feel like we’re building the insides of a game.”
Student F: “Loops seem like they can do some really fun stuff if you get creative!”
■ Teacher’s Closing Thoughts
“When you learn how to use loops, you’ve taken your first step into automation. Instead of repeating tasks manually, a program does it for you. That’s at the heart of system development.”
■ Next Week’s Preview: Let’s Explore Lists (Arrays)!
Next week, we’ll move on to lists (arrays)—tools that help us handle multiple pieces of data at once. Think class rosters, test scores, shopping lists… How can we store and use that kind of data? Look forward to it!
Our first-year students are gradually collecting more and more “tools.” Next, they’ll enter the phase of learning how to “manipulate data” with them.