A sequence of positive and non-zero integers called palindromic if it can be read the same forward and backward, for example:
15 2 6 4 6 2 15
20 3 1 1 3 20
We have a special kind of palindromic sequences, let's call it a special palindrome.
A palindromic sequence is a special palindrome if its values don't decrease up to the middle value, and of course they don't increase from the middle to the end.
The sequences above is NOT special, while the following sequences are:
1 2 3 3 7 8 7 3 3 2 1
2 10 2
1 4 13 13 4 1
Let's define the function F(N), which represents the number of special sequences that the sum of their values is N.
For example F(7) = 5 which are : (7), (1 5 1), (2 3 2), (1 1 3 1 1), (1 1 1 1 1 1 1)
Your job is to write a program that compute the Value F(N) for given N's.
The Input consists of a sequence of lines, each line contains a positive none zero integer N less than or equal to 250. The last line contains 0 which indicates the end of the input.
Print one line for each given number N, which it the value F(N).
## Input
The Input consists of a sequence of lines, each line contains a positive none zero integer N less than or equal to 250. The last line contains 0 which indicates the end of the input.
## Output
Print one line for each given number N, which it the value F(N).
[samples]
**Definitions**
Let $ D = \{0, 1, 2, 3, 4, 5, 6, 7, 8, 9\} $ be the set of decimal digits.
Define a mapping $ f: D \to D $ such that $ f(d) $ is the digit that results from reflecting $ d $ vertically (i.e., flipping upside down) in a 7-segment LED display:
- $ f(0) = 0 $, $ f(1) = 1 $, $ f(2) = 5 $, $ f(5) = 2 $, $ f(6) = 9 $, $ f(8) = 8 $, $ f(9) = 6 $,
- $ f(3), f(4), f(7) $ are undefined (invalid under reflection).
A digit sequence $ s = d_1 d_2 \dots d_n $ is **vertically symmetric** if $ f(d_i) = d_{n+1-i} $ for all $ i \in \{1, \dots, n\} $, and $ f(d_i) $ is defined for all $ i $.
A digit sequence $ s $ is **horizontally symmetric** if $ d_i = d_{n+1-i} $ for all $ i \in \{1, \dots, n\} $.
A number is **symmetric** if it is vertically symmetric or horizontally symmetric (or both).
**Constraints**
Let $ A, B \in \mathbb{Z} $ such that $ 0 \le A \le B \le 10^{18} $.
**Objective**
Compute the number of symmetric integers in the interval $ [A, B] $, modulo $ 10^9 + 7 $.