C Program to Count the number of digits in an integer

C Program to Count the number of digits in an integer

Input: 12345

Output: number of digits = 5