Hsueh- especially likes pleasure number because these numbers make people feel happy.
A number is a pleasure number, iff it is an integer, and the greatest common factor of the product of its digits and the number itself is not $$$1$$$.
It is worth noting that:
For instance:
Hsueh- wants to know how many pleasure numbers in the range $$$[A, B]$$$.
The first line contains a single integer $$$T(1 \leq T \leq 10^4)$$$, denoting the number of test case.
For next $$$T$$$ lines, each line contains two integer $$$A, B(1 \leq A, B \leq 10^{18})$$$, representing the range $$$[A, B]$$$.
For each test case, print a single integer, denoting the answer.
2 1 2 3 4
1 2
| Название |
|---|


