x = input(" Enter the integer :") # asking for the integer from the user

sum = 0
for i in x: # iterating the integer with a for loop 
    sum = sum + int(i) # taking the sum of the digits 
print(sum) # printing the sum 
