# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
54294 | 2018-07-03T06:12:06 Z | 창조론자(#2048) | Aliens (IOI07_aliens) | C++11 | 1000 ms | 660 KB |
#include<stdio.h> #include<string.h> long long min(long long a, long long b) { if (a < b)return a; return b; } char X[10]; bool qr(long long x, long long y) { printf("examine %lld %lld\n", x, y); fflush(stdout); scanf("%s", X); if (strcmp(X, "true") == 0)return 1; return 0; } void sol(long long x, long long y) { printf("solution %lld %lld\n", x, y); } int main() { long long i,j,n, sx, sy, bef; scanf("%lld%lld%lld",&n, &sx, &sy); long long mx = min(n - sx + 1, n - sy + 1) / 5, cnt = 0; bef = sx + mx * 5 - 1; while (!qr(sx + 5 * mx - 1, sy)) { bef = sx + mx * 5 - 1; mx = (mx * 4) / 5; } long long s = sx + mx * 5 - 1, e = bef, res; while (s <= e) { long long m = (s + e) / 2; if (qr(m, sy)) res = m, s = m + 1; else e = m - 1; } long long m = (res + 1 - sx) / 5; sol((2 * sx + 5 * m - 1) / 2, (2 * sy + 5 * m - 1) / 2); return 0; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 3 ms | 296 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 3 ms | 440 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 440 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 1064 ms | 452 KB | Time limit exceeded |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 452 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 452 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 476 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 524 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 660 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 660 KB | Incorrect |
2 | Halted | 0 ms | 0 KB | - |