Skip to main content
← CoursesPython FoundationsModule 1 · Fundamentals of syntaxfor loopfill12 / 170
💬 Discuss🧪 Playground+60 XP
Task
📝 **Task:** Fill in the blank so the loop prints numbers 1 to 5. 📋 **Steps:** - Currently `for i in ___` — the range is missing - Use `range(1, 6)` (to include 5, pass right bound + 1) 💡 **Similar example:** ```python for n in range(1, 4): print(n) # 1 # 2 # 3 ``` ⚠️ **Hint:** `range(a, b)` yields `a, a+1, ..., b-1`. Right bound is NOT included. 🎯 **Expected output:** ``` 1 2 3 4 5 ```

Keep going

✏️ Write your code here
🐍
Loading Python...
First visit only — ~5-10s. Stays cached afterward.
📊 Result
Press Run to see result...
📣 Help someone learn PythonShare this lesson with a friend — the first 15 are free, no signup.Tweet

💬 Discussion

Be the first to ask a question or share a tip.
Sign in to join the discussion. Reading is free.
Loading discussion…