Posts by Israel • 21 points
1 post
-
2
votes11
answers37801
viewsA: Compute sum of digits of a number
I was also doubtful about this program, and based on your achievement by making the adjustments below. n = int(input("Digite um número inteiro: ")) soma = 0 while (n > 0): resto = n % 10 n = n //…