# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1132195 | finalventure | Lost in the cycle (IOI19_cycle) | C++20 | 0 ms | 396 KiB |
#include "cycle.h"
int N;
inline int back(int k) {
return N-k;
}
void escape(int n) {
N = n;
int size = n / 2;
int ok = jump(0);
while (size) {
if (ok) {
ok = jump(size);
} else {
ok = jump(back(size));
}
if (size == 1) size = 0;
else size = (size + 1) / 2;
}
if (!ok) jump(back(1));
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |