C program to check whether a number is a happy number or not

OUTPUT: