# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1143690 | sano | Hotter Colder (IOI10_hottercolder) | C++20 | 481 ms | 101748 KiB |
#include "grader.h"
#include<iostream>
#include<vector>
using namespace std;
int HC(int n) {
int l = 1;
int r = n;
while (l < r) {
Guess(l);
int x = Guess(r);
int mid = (l + r) / 2;
if (x == 0) {
return mid;
}
if (x == -1) {
r = mid - ((l + r) % 2 == 1);
}
if (x == 1) {
l = mid + 1;
}
}
return -1;
}
# | 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... |