Repeating Sum Calculator Using Python
In This Python Program, You can easily Add Numbers Just By Entering Number and Pressing Enter, You Can Do It As Much as You Want, Coz this is in a While Loop.
You Do not Have To Install any Python Library to Run this Program, Very Simple and Short Codes are Given, Just Copy them and Paste In Your IDE or Python Official IDLE.
sum = 0
while (True):
userInput = int(input("Enter the Price : \n"))
if (userInput!='q'):
sum = sum + int(userInput)
print("Your Order Total So far : ", sum)
else:
print("Thanks For Using Our Calculator")
print("The Total Sum : ", sum )
break
0 Comments:
Post a Comment