Easy
Given a non-negative integer n, repeatedly add all its digits until the result has only one digit, and return it.
n
Input: n = 38 Output: 2 Explanation: 3 + 8 = 11, 1 + 1 = 2.
Input: n = 0 Output: 0