Question
Encrypted Badge Message
An event app compresses badge messages using numbers. The number
You are given a string of digits. Count how many different original messages it could represent. Since the answer can be large, print it modulo
The twist: a
Input
The only line contains a digit string KaTeX can only parse string typed expression.
Output
Print a single integer — the number of valid decodings modulo KaTeX can only parse string typed expression.
Example
Example 1:
Input
The possible decodings are KaTeX can only parse string typed expression, KaTeX can only parse string typed expression, and KaTeX can only parse string typed expression.
Example 2:
Input
A code cannot start with a standalone KaTeX can only parse string typed expression.
Input
226Output3ExplanationThe possible decodings are KaTeX can only parse string typed expression, KaTeX can only parse string typed expression, and KaTeX can only parse string typed expression.
Example 2:
Input
06Output0ExplanationA code cannot start with a standalone KaTeX can only parse string typed expression.