'how to make repetitive request of the input?
I write this code to get the of digit of the number inputted by the user
the problem I don't know how to make it repetitive to user to get the request of entering the input again and again
x=input("enter the number you want to get the sum of its' sum: ")
z=0
for a in x:
z=z+int(a)
print(z)
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|