System of equations
After spending time with Marysia at the zoo, Stepan finally sat down to tackle his algebra homework. However, his thoughts are still on Marysia, making it difficult for him to solve the following problem:
Let (S(n)) represent the sum of the digits of the number (n), where (n) is a non-negative integer. Determine the number of solutions to the following system:
[ X + Y = A ]
[ S(X) + S(Y) = S(A) ]
All numbers involved are non-negative integers.
Help him find the solution.
Input
The input consists of a single number (A) ((0 A 10^100)), provided without leading zeros.
Output
Output a single number, which is the count of solutions to this system.
Explanation for the example:
In the given example, there are 4 solutions: ((x = 0, y = 11)), ((x = 11, y = 0)), ((x = 1, y = 10)), ((x = 10, y = 1)).