algorithms.tutorialhorizon.com
Get the Sum of Digits in a number till it become a single digit | Algorithms
Given a number, Write a program to get the sum of digits in a number till it become a single digit. Example: N = 999 -> 9+9+9 = 27-> 2+7 = 9, N = 789 -> 7+8+9= 24-> 2+4 = 6