CJCoding With Joseph
15free / daySign inCreate account
← Back to Question List
Python Code Walkthrough #13

Two Accumulators

easyLoops

📄 Code

Read carefully — what does this print?
1total: int = 0
2count: int = 0
3for value in [5, 10, 15]:
4 total = total + value
5 count = count + 1
6print(total, count)
7print(total / count)

🎯 Your Answer