Question #145530

Write code using the range function to add up the series 20, 30, 40, ... 90 and print the resulting sum each step along the way


Expert's answer

curr_sum = 0
for i in range(20, 100, 10):
    curr_sum += i
    print("Current sum:", curr_sum)

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

LATEST TUTORIALS
APPROVED BY CLIENTS