Given a non-negative integer , repeatedly add all its digits until the result has only one digit. Return that digit.
For example, if , add . Then add . Return .
There's a simple loop solution, but also a mathematical shortcut using modulo. Try the loop first.