#include "lokahia.h"
int FindBase(int N){
int prev = 0, cur = N - 1, cnt = 0;
while (true) {
int temp = CollectRelics(prev, cur);
if (temp == -1) cur = cnt++, prev = N - 1;
if (temp == cur) return cur;
prev = cur;
cur = temp;
}
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
492 KB |
Wrong |
2 |
Incorrect |
1 ms |
620 KB |
Wrong |
3 |
Incorrect |
1 ms |
620 KB |
Wrong |
4 |
Incorrect |
1 ms |
492 KB |
Wrong |
5 |
Correct |
1 ms |
492 KB |
Correct : C = 2 |
6 |
Incorrect |
1 ms |
492 KB |
Wrong |
7 |
Incorrect |
1 ms |
620 KB |
Wrong |
8 |
Incorrect |
1 ms |
620 KB |
Wrong |
9 |
Correct |
1 ms |
492 KB |
Correct : C = 2 |
10 |
Correct |
1 ms |
492 KB |
Correct : C = 2 |
11 |
Correct |
1 ms |
620 KB |
Correct : C = 2 |
12 |
Correct |
1 ms |
492 KB |
Correct : C = 2 |
13 |
Incorrect |
1 ms |
620 KB |
Wrong |
14 |
Correct |
1 ms |
620 KB |
Correct : C = 2 |
15 |
Incorrect |
1 ms |
492 KB |
Wrong |
16 |
Incorrect |
1 ms |
620 KB |
Wrong |
17 |
Correct |
1 ms |
620 KB |
Correct : C = 2 |
18 |
Incorrect |
1 ms |
620 KB |
Wrong |
19 |
Incorrect |
1 ms |
620 KB |
Wrong |
20 |
Incorrect |
1 ms |
620 KB |
Wrong |
21 |
Correct |
1 ms |
492 KB |
Correct : C = 2 |
22 |
Incorrect |
1 ms |
620 KB |
Wrong |
23 |
Incorrect |
1 ms |
492 KB |
Wrong |
24 |
Incorrect |
1 ms |
620 KB |
Wrong |
25 |
Correct |
1 ms |
492 KB |
Correct : C = 2 |
26 |
Incorrect |
1 ms |
492 KB |
Wrong |
27 |
Correct |
1 ms |
620 KB |
Correct : C = 2 |