In: Computer Science
Do Programming Exercise 1 (Bug collector) - Page 203 (Page 180 is good inspiration: Output should look like this... Enter the number of bugs collected today on day 1 : 10 Enter the number of bugs collected today on day 2 : 5 Enter the number of bugs collected today on day 3 : 20 Enter the number of bugs collected today on day 4 : 0 Enter the number of bugs collected today on day 5 : 40 Total bugs collected: 75
bugs=0
#looping from 1 to 5 days
#collecting bugs and adding to sum
for i in range(1,6):
bugs+=int(input("Enter the number of bugs collected today on day "+str(i)+" : "))
#printing total bugs
print("Total bugs collected: ",bugs)
Note : If you like my answer please rate and help me it is very Imp for me