write a program to find the sum of digit in a number
Answers
Answered by
22
- int main() { int n, t, sum = 0, remainder;
- int main() { int n, t, sum = 0, remainder;print("Enter an integer\n"); scanf("%d", &n);
- int main() { int n, t, sum = 0, remainder;print("Enter an integer\n"); scanf("%d", &n);t = n;
- int main() { int n, t, sum = 0, remainder;print("Enter an integer\n"); scanf("%d", &n);t = n;while (t != 0) { remainder = t % 10; sum = sum + remainder; t = t / 10; }
- int main() { int n, t, sum = 0,
Similar questions