#arc089a. [arc089_a]Traveling
[arc089_a]Traveling
Problem Statement
AtCoDeer the deer is going on a trip in a two-dimensional plane. In his plan, he will depart from point at time , then for each between and (inclusive), he will visit point at time .
If AtCoDeer is at point at time , he can be at one of the following points at time : , , and . Note that he cannot stay at his place. Determine whether he can carry out his plan.
Constraints
- ( )
- All input values are integers.
Input
Input is given from Standard Input in the following format:
Output
If AtCoDeer can carry out his plan, print Yes
; if he cannot, print No
.
Sample Input 1
2
3 1 2
6 1 1
Sample Output 1
Yes
For example, he can travel as follows: , , , , , , then .
Sample Input 2
1
2 100 100
Sample Output 2
No
It is impossible to be at two seconds after being at .
Sample Input 3
2
5 1 1
100 1 1
Sample Output 3
No