O. Rainbow Numbers
题号:NC223979
时间限制:C/C++/Rust/Pascal 1秒,其他语言2秒
空间限制:C/C++/Rust/Pascal 256 M,其他语言512 M
64bit IO Format: %lld

题目描述

Define a rainbow number as an integer that, when represented in base 10 with no leading zeros, has no two adjacent digits the same. 
Given lower and upper bounds, count the number of rainbow numbers between them (inclusive). 

输入描述:

The first line of input contains a single integer , which is the lower bound. 
The second line of input contains a single integer , which is the upper bound.It is guaranteed that L ≤ U. 
Note that the limits are not a misprint; L and U can be up to 105 digitslong. 

输出描述:

Output a single integer, which is the number of rainbow numbers between L and U (inclusive). Because this number may be very large, output it modulo 998,244,353. 
示例1

输入

复制
1
10

输出

复制
10
示例2

输入

复制
12345
65432

输出

复制
35882