#P2520. [HAOI2011] 向量
[HAOI2011] 向量
Description
Given a pair of numbers , you may use any of the vectors , , , , , , , in arbitrary quantities. Determine whether you can form another vector .
Note: Here, “form” means that the sum of the vectors you choose equals .
Input Format
The first line contains the number of test cases ().
The next lines each contain four integers ().
Output Format
Output lines. Each line is Y if it is possible, or N if it is not.
3
2 1 3 3
1 1 0 1
1 0 -2 3
Y
N
Y
Hint
Sample Explanation
Group 1: .
Group 3: .
Translated by ChatGPT 5
京公网安备 11011102002149号