#include <bits/stdc++.h>
using namespace std;
int T;
int main() {
cin >> T;
while (T--) {
int A;
cin >> A;
assert(A==20||A==200);
if (A==20) {
int ii, ij;
while (ii != 0) {
for (int i = 2; i < 3; i++) {
for (int j = 2; j < 7; j++) {
cout << i << ' ' << j << '\n';
cout << flush;
cin >> ii >> ij;
if(ii == -1) return 0;
if (ii==0) break;
}
if (ii==0) break;
}
if (ii==0) break;
}
} else {
int ii, ij;
while (ii != 0) {
for (int i = 2; i < 3; i++) {
for (int j = 2; j < 67; j++) {
cout << i << ' ' << j << '\n';
cout << flush;
cin >> ii >> ij;
if(ii == -1) return 0;
if (ii==0) break;
}
if (ii==0) break;
}
if (ii==0) break;
}
}
}
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Execution timed out |
5 ms |
384 KB |
Time limit exceeded (wall clock) |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
16 ms |
384 KB |
failed to make a rectangle in 1000 deployments |