Accepted
Code
#include<bits/stdc++.h>
using namespace std;
#define optimize() ios_base :: sync_with_stdio (0); cin.tie(0); cout.tie(0);
int main()
{
optimize();
int t; cin>>t;
while(t--)
{
int n, m;
cin>>n>>m;
int x,y;
cin>>x>>y;
int p,q;
cin>>p>>q;
if(abs(x-p) % 2 == 0 && abs(y-q)%2==0)
{
cout<<"Yes"<<endl;
}
else if(abs(x-p) % 2 != 0 && abs(y-q)%2!=0)
{
cout<<"Yes"<<endl;
}
else cout<<"No"<<endl;
}
}
Information
- Submit By
- Type
- Submission
- Problem
- P1115 Destination
- Contest
- LU IUJPC : Sylhet Division 2024, Mock Round
- Language
- C++17 (G++ 13.2.0)
- Submit At
- 2024-12-07 11:27:03
- Judged At
- 2024-12-07 11:27:03
- Judged By
- Score
- 100
- Total Time
- 143ms
- Peak Memory
- 900.0 KiB