# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
767389 |
2023-06-26T17:35:34 Z |
sraeli |
Archery (IOI09_archery) |
C |
|
324 ms |
1844 KB |
#include <stdio.h>
int main() {
int N, R;
if (scanf("%d %d", &N, &R) != 2) {
return 1;
}
int myRank;
if (scanf("%d", &myRank) != 1) {
return 1;
}
int competitorRanks[400000];
for (int i = 0; i < 2 * N - 1; i++) {
if (scanf("%d", &competitorRanks[i]) != 1) {
return 1;
}
}
int target = 1; // Alvo inicial (alvo 1)
int round = 1;
while (round < R) {
if (target == 1) {
if (myRank < competitorRanks[0]) {
target = N; // O perdedor do alvo 1 se move para o alvo N
}
} else {
if (myRank < competitorRanks[(target - 2) * 2]) {
target--; // Os vencedores se movem para a esquerda
}
}
round++;
}
printf("%d\n", target);
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
2 |
Incorrect |
20 ms |
1840 KB |
Output isn't correct |
3 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
4 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
5 |
Incorrect |
1 ms |
1812 KB |
Output isn't correct |
6 |
Incorrect |
48 ms |
1824 KB |
Output isn't correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
2 |
Incorrect |
41 ms |
1824 KB |
Output isn't correct |
3 |
Incorrect |
17 ms |
1748 KB |
Output isn't correct |
4 |
Incorrect |
3 ms |
1748 KB |
Output isn't correct |
5 |
Incorrect |
25 ms |
1748 KB |
Output isn't correct |
6 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
7 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
8 |
Incorrect |
128 ms |
1828 KB |
Output isn't correct |
9 |
Incorrect |
14 ms |
1844 KB |
Output isn't correct |
10 |
Incorrect |
4 ms |
1748 KB |
Output isn't correct |
11 |
Incorrect |
4 ms |
1748 KB |
Output isn't correct |
12 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
13 |
Incorrect |
22 ms |
1836 KB |
Output isn't correct |
14 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
15 |
Incorrect |
5 ms |
1840 KB |
Output isn't correct |
16 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
17 |
Incorrect |
324 ms |
1824 KB |
Output isn't correct |
18 |
Incorrect |
13 ms |
1844 KB |
Output isn't correct |
19 |
Incorrect |
2 ms |
1748 KB |
Output isn't correct |
20 |
Incorrect |
3 ms |
1748 KB |
Output isn't correct |
21 |
Incorrect |
4 ms |
1748 KB |
Output isn't correct |
22 |
Incorrect |
5 ms |
1832 KB |
Output isn't correct |
23 |
Incorrect |
26 ms |
1836 KB |
Output isn't correct |
24 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
25 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
26 |
Incorrect |
2 ms |
1748 KB |
Output isn't correct |
27 |
Incorrect |
5 ms |
1748 KB |
Output isn't correct |
28 |
Incorrect |
19 ms |
1844 KB |
Output isn't correct |
29 |
Incorrect |
2 ms |
1748 KB |
Output isn't correct |
30 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
31 |
Incorrect |
4 ms |
1748 KB |
Output isn't correct |
32 |
Incorrect |
25 ms |
1844 KB |
Output isn't correct |
33 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
34 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
35 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
36 |
Incorrect |
2 ms |
1748 KB |
Output isn't correct |
37 |
Incorrect |
3 ms |
1748 KB |
Output isn't correct |
38 |
Incorrect |
5 ms |
1748 KB |
Output isn't correct |
39 |
Incorrect |
1 ms |
1748 KB |
Output isn't correct |
40 |
Incorrect |
23 ms |
1844 KB |
Output isn't correct |
41 |
Incorrect |
112 ms |
1748 KB |
Output isn't correct |
42 |
Incorrect |
74 ms |
1824 KB |
Output isn't correct |
43 |
Incorrect |
14 ms |
1840 KB |
Output isn't correct |
44 |
Incorrect |
47 ms |
1816 KB |
Output isn't correct |
45 |
Incorrect |
11 ms |
1748 KB |
Output isn't correct |
46 |
Incorrect |
5 ms |
1748 KB |
Output isn't correct |
47 |
Incorrect |
151 ms |
1820 KB |
Output isn't correct |