# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
982278 | Vedang1006 | The Big Prize (IOI17_prize) | C++14 | 1 ms | 596 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 "prize.h"
int find_best(int n) {
int i = 0;
for (int jumpSize = 30; jumpSize >= 0; jumpSize--)
{
while (i + (1<<jumpSize) < n && ask(i + (1<<jumpSize))[1] == 1) i += (1<<jumpSize);
}
return i + 1;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |