C program to count digits of a number using recursion
In this C program, we are going to learn how to count total number of digits of a number using recursion?
Given an integer number and we have to count the digits using recursion using C program.
In this program, we are reading an integer number and counting the total digits, here countDigits() is a recursion function which is taking number as an argument and returning the count after recursion process.
Input number: 123
Total digits are: 3