Count DigitsEasy

Count Digits

EasyPractice library · +10 XPrecursionmath

Given a non-negative integer N, write a program to count the number of digits it has. You must use recursion.

Input

A single non-negative integer N.

Output

A single integer representing the number of digits in N.

Constraints

0 <= N <= 10^9

Time limit 1 s (native code; slower languages get more)Memory 256 MB12 hidden tests

Example 1

Input
12345
Output
5

The number 12345 has 5 digits.

Example 2

Input
7
Output
1

The number 7 has 1 digit.

Hints