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 "bits/stdc++.h"
#include "cycle.h"
using namespace std;
void escape(int n) {
int lo = 1, hi = n;
int a = 0, cur = 0;
while (lo < hi) {
int mid = lo + (hi-lo) / 2;
cur += (mid + a);
cur %= n;
if (jump((mid + a) % n)) {
hi = mid;
} else {
lo = mid+1;
}
a = n - mid;
}
jump((n/2 + lo + a) % n);
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |