Happy Number

A happy number eventually reaches 1 when replaced by the sum of the squares of its digits repeatedly. Return true if n is happy.

Examples
Input: 19
Output: true
Hints

Happy Number

A happy number eventually reaches 1 when replaced by the sum of the squares of its digits repeatedly. Return true if n is happy.