АВТ
Language: Russian
English

Remote Training on Programming

Problems Online status Contests
News FAQ E-learning
For authors:
Register  ||  Login
 
Hello, Guest! Please login or register.

1592. Parquet

Time Limit: 0.5 seconds
Memory Limit:262144KB
Points:100
View Problem Statistics Submit Problem added debug

During the redecoration of the H&H office the decision was made to lay a parquet floor. The floor has a form of N × M rectangle. Each parquet hoard is a 2 × 3 rectangle.

Help H&H maintenance departement to determine if it is possible to lay the parquet with available hoards or not. The parquet hoards cannot be breaked.

Входные данные

The first line of the input contains the number of test cases K (1 ≤ K ≤ 10). Each of the following K lines contains two integer numbers — N and M (1 ≤ N, M ≤ 109).

Выходные данные

For each test case from the input write to the output separate string with word "Yes" if the answer is positive or word "No" in the opposite case.

Пример

Входные данные
3
3 2
5 12
7 8
Выходные данные
Yes
Yes
No


View Problem Statistics Submit Problem discussion Author/source:
Problems from Contests and Camps / Trainings in Perm 2009 / 07.07.09 Big Contest /
1591. J - Selection 1592.
time generating 0.094 sec.
© Copyright VSU, AVT, Nosov D.A., Andrianov I.A.