# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
41048 | 2018-02-12T07:20:08 Z | pica4500 | Hotter Colder (IOI10_hottercolder) | C++ | 10000 ms | 20216 KB |
#include "grader.h" #include <iostream> using namespace std; pair<int, int> cache[501][501]; pair<int, int> get(int lo, int hi) { pair<int, int>& ret = cache[lo][hi]; if (ret.first != -2) return ret; ret.first = Guess(lo); ret.second = Guess(hi); return ret; } int HC(int N){ for (int i = 1; i <= N; i++) { for (int j = 1; j <= N; j++) { cache[i][j].first = -2; cache[i][j].second = -2; } } int lo = 1; int hi = N; bool flag = 0; while (lo < hi) { pair<int, int> loHi = get(lo, hi); int mid = (lo + hi) / 2; if (loHi.second == 0) return mid; else if (loHi.second == 1) lo = mid + 1; else hi = mid; } return lo; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 10019 ms | 3320 KB | Time limit exceeded |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 10091 ms | 3224 KB | Time limit exceeded |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 10022 ms | 3192 KB | Time limit exceeded |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 428 ms | 20216 KB | Execution killed with signal 11 (could be triggered by violating memory limits) |