Python in 100 days > Day 19

Problem description

Question is bug solve the following:

total = 0
for number in range 100:
  total += number
  print(total)

Anwser given by Replit is the following: Add ( ) to 100

total = 0
for number in range (100):
  total += number
  print(total)

Expected behavior

This should print number 0 to 99

Actual behavior

Print 0 to 4950 because

Steps to reproduce

Go to replit learn Go 100 days python day 19

Browser

chrome

OS

windows

Device if mobile

n/a

Plan

free

Please upload screenshots

1 Like

3 posts were merged into an existing topic: Day 019 - Project 19 : Loan Calculator