# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
41028 | esspks21 | Hotter Colder (IOI10_hottercolder) | C++14 | 815 ms | 8204 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include "grader.h"
int HC(int N) {
int left = 1;
int right = N;
while (left <= right) {
if (left == right) return (left + right) >> 1;
Guess(left);
int temp = Guess(right);
if (temp == 0) // same
return (left + right) / 2;
if (temp == 1) // hotter
left = (left + right) / 2 + 1;
if (temp == -1) // colder
right = (left + right) / 2;
}
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |