A. Sum Fun
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output
"Judge things by their sum."
Wise Man

You are given two integers $$$n$$$, $$$m$$$. Please determine if there exists a positive integer $$$s$$$ such that the following conditions are true:

  • It does not contain the digit $$$0$$$;‎‎ ‎
  • It consists of $$$n$$$ digits;
  • The sum of its digits is exactly $$$m$$$;
  • It is a palindrome.$$$^\dagger$$$

$$$^\dagger$$$ A positive integer $$$a$$$ is called a palindrome when it reads the same when the order of digits is reversed.

Input

Each test contains multiple test cases. The first line contains the number of test cases $$$t$$$ ($$$1 \le t \le 10^4$$$). The description of the test cases follows.

The only line of each test case contains two integers $$$n$$$ and $$$m$$$ ($$$1 \le n,m \le 10^8$$$) — the number of digits and the sum of digits.

Output

For each test case, if there exists a valid integer $$$s$$$, print "YES"; otherwise, print "NO".

You can output the answer in any case (For example, the strings "yEs", "yes", "Yes", and "YeS" will be recognized as positive responses).

Example
Input
7
7 10
8 10
7 15
10 20
90 100
10 78
2 5
Output
YES
YES
YES
YES
YES
YES
NO
Note

In the first test case, $$$2\,112\,112$$$ satisfies all four conditions:

  • $$$2\,112\,112$$$ does not contain the digit $$$0$$$.
  • $$$2\,112\,112$$$ consists of $$$7$$$ digits, and the sum of digits is $$$10$$$.
  • $$$2\,112\,112$$$ is a palindrome.

Therefore, $$$2\,112\,112$$$ can be an answer.

In the second test case, it can be shown that there is no integer $$$s$$$ which satisfies all the conditions.

In the fourth test case, $$$1\,232\,222\,321$$$ can be an answer.