You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given a positive integer N, determine the number of times you must add the digits in it to reach a single digit. For example, if N = 347, then the answer is 2 because 3 + 4 + 7 = 14 and 1 + 4 = 5, i.e. we reached a single digit in 2 steps.