Wrong Answer
Code
#include<bits/stdc++.h>
using namespace std;
int32_t main() {
ios_base::sync_with_stdio(false);
cin.tie(0); cout.tie(0);
int t; cin >> t;
while (t--) {
int n, m; cin >> n >> m;
int x, y; cin >> x >> y;
int p, q; cin >> p >> q;
bool ans = true;
if (p > m or p > n or q > m or q > n) ans = 0;
else if (x == p or x == q or y == p or y == q) ans = 0;
else if (abs(x - y) != abs(p - q)) ans = 0;
if (ans) cout << "Yes\n";
else cout << "No\n";
}
}
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 10:54:05
- Judged At
- 2024-12-07 10:54:05
- Judged By
- Score
- 10
- Total Time
- 59ms
- Peak Memory
- 936.0 KiB