Submission #225902

#TimeUsernameProblemLanguageResultExecution timeMemory
225902pavementLost in the cycle (IOI19_cycle)C++17
33 / 100
5 ms384 KiB
#include "cycle.h" #include <bits/stdc++.h> using namespace std; void escape(int n) { int cur = 0, lo = 0, hi = n - 1, ans = -1; while (lo <= hi) { int mid = (lo + hi) >> 1; bool x = jump(mid >= cur ? mid - cur : n - cur + mid); cur = mid; if (x) ans = mid, hi = mid - 1; else lo = mid + 1; } jump((ans >= cur ? ans - cur : n - cur + ans) + n / 2); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...