# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
225784 | 2020-04-21T15:16:03 Z | Blerargh | Lost in the cycle (IOI19_cycle) | C++17 | 5 ms | 384 KB |
#include <bits/stdc++.h> #include "cycle.h" using namespace std; void escape(int n){ bool chk; int half = n/2; if (!jump(half)){ chk = jump(n-half); } int l=0, r=half, prevjump=n; while (l<r){ int mid = (l+r)/2; int tojump = mid+n-prevjump; if (tojump>=n) chk=jump(n-prevjump), prevjump=n; if (jump(mid+n-prevjump)) l=mid; else r=mid-1; prevjump = mid; } chk = jump(l+n-prevjump); return; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 5 ms | 384 KB | Invalid argument. |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 5 ms | 276 KB | Invalid argument. |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 5 ms | 384 KB | Invalid argument. |
2 | Halted | 0 ms | 0 KB | - |