Python Program to Count the Number of Digits Present In a Number Using inbuilt Method
# Count the Number of Digits Present In a Number Using inbuilt methods in python num = 123456 # first convert the integer value into string by using str(). Then, we find the length of the string using len(). print(len(str(num)))
Output:
6