Submission #998961

#TimeUsernameProblemLanguageResultExecution timeMemory
99896112345678Lost in the cycle (IOI19_cycle)C++17
100 / 100
1 ms352 KiB
#include "cycle.h" #include <bits/stdc++.h> using namespace std; void escape(int n) { int lst=0; if (!jump(n/2)) jump(n/2); for (int i=30; i>=0; i--) { if ((1<<i)>=(n+1)/2) continue; if (lst) lst=!jump((-(1<<i))+n); else lst=!jump(1<<i); //cout<<"debug "<<i<<' '<<lst<<'\n'; } if (lst) jump(n-1); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...