Given an integer n, return simplified version of n, simplified version means adding all the individual digits of all the n to form another number n and repeat this task to get a final single digit number which will be our answer.
Answers
Answered by
0
Answer:
Step-by-step explanation:
1. Input Number
2. Check number of Digit
3. Sum of Digits = 0
4. if Number of Digit > 1
5. Then Find the Each Digit
6. Sum of Digits = Sum of Digits + Each Digit
7 if (Sum of Digit > 1 )
8 . Repeat 5 & 6
9 Else Print Sum of Digits
10 Else Print - Number
Similar questions
Social Sciences,
5 months ago
Math,
5 months ago
Science,
5 months ago
Biology,
1 year ago
Math,
1 year ago