# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
745507 | 2023-05-20T09:11:54 Z | boris_mihov | Shortcut (IOI16_shortcut) | C++17 | 1 ms | 340 KB |
#include "shortcut.h" #include <algorithm> #include <iostream> #include <cassert> #include <numeric> #include <vector> typedef long long llong; const int MAXN = 1000000 + 10; const llong INF = 1e16; int n, c; struct BIT { llong tree[MAXN]; void reset() { std::fill(tree + 1, tree + 1 + n, -INF); } void update(int pos, llong value) { for (int idx = pos ; idx <= n ; idx += idx & (-idx)) { tree[idx] = std::max(tree[idx], value); } } llong query(int pos) { llong res = -INF; for (int idx = pos ; idx > 0 ; idx -= idx & (-idx)) { res = std::max(res, tree[idx]); } return res; } }; BIT tree; struct Point { llong x, y; }; struct Rectangle { Point low, up; Rectangle() { low.x = low.y = -INF; up.x = up.y = INF; } bool isInside(Point p) { return low.x <= p.x && low.y <= p.y && p.x <= up.x && p.y <= up.y; } }; int l[MAXN]; int d[MAXN]; int sortedPlus[MAXN]; int sortedMinus[MAXN]; llong p[MAXN]; bool check(llong allowed) { tree.reset(); Rectangle area; llong maxSub = -INF; int idxSum = 0; int idxSub = 0; for (int i = 1 ; i <= n ; ++i) { if (i > 1 && maxSub > allowed - d[i] - p[i]) { area.low.y = std::max(area.low.y, p[i] + d[i] + maxSub + c - allowed); area.up.x = std::min(area.up.x, p[i] - d[i] - maxSub - c + allowed); } maxSub = std::max(maxSub, d[i] - p[i]); } llong maxSum; int ptr = n + 1; for (int i = 1 ; i <= n ; ++i) { if (sortedPlus[i] == 1) { continue; } while (ptr > 1 && p[sortedPlus[i]] + d[sortedPlus[i]] - p[sortedMinus[ptr - 1]] + d[sortedMinus[ptr - 1]] > allowed) { ptr--; tree.update(sortedMinus[ptr], p[sortedMinus[ptr]] + d[sortedMinus[ptr]]); } if (ptr <= n) { maxSum = tree.query(sortedPlus[i] - 1); area.low.x = std::max(area.low.x, p[sortedPlus[i]] + d[sortedPlus[i]] + maxSum + c - allowed); area.up.y = std::min(area.up.y, p[sortedPlus[i]] - d[sortedPlus[i]] - maxSum - c + allowed); } } ptr = 1; for (int i = 2 ; i <= n ; ++i) { while (ptr < i && (p[ptr] + p[i] < area.low.x || p[i] - p[ptr] > area.up.y) && (p[i] + p[ptr + 1] <= area.up.x && p[i] - p[ptr + 1] >= area.low.y)) { ptr++; } if (ptr < i) { Point curr = {p[i] + p[ptr], p[i] - p[ptr]}; if (area.isInside(curr)) { return true; } } } return false; } llong find_shortcut(int N, std::vector <int> L, std::vector <int> D, int C) { n = N; c = C; for (int i = 0 ; i < n - 1 ; ++i) { l[i + 1] = L[i]; } for (int i = 0 ; i < n ; ++i) { d[i + 1] = D[i]; } p[1] = 0; for (int i = 2 ; i <= n ; ++i) { p[i] = p[i - 1] + l[i - 1]; } std::iota(sortedPlus + 1, sortedPlus + 1 + n, 1); std::iota(sortedMinus + 1, sortedMinus + 1 + n, 1); std::sort(sortedPlus + 1, sortedPlus + 1 + n, [&](int x, int y) { return d[x] + p[x] < d[y] + p[y]; }); std::sort(sortedMinus + 1, sortedMinus + 1 + n, [&](int x, int y) { return d[x] - p[x] < d[y] - p[y]; }); llong l = -1, r = INF, mid; while (l < r - 1) { mid = (l + r) / 2; if (!check(mid)) l = mid; else r = mid; } return r; }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 340 KB | n = 4, 80 is a correct answer |
2 | Correct | 1 ms | 340 KB | n = 9, 110 is a correct answer |
3 | Correct | 0 ms | 340 KB | n = 4, 21 is a correct answer |
4 | Correct | 1 ms | 340 KB | n = 3, 4 is a correct answer |
5 | Correct | 0 ms | 340 KB | n = 2, 62 is a correct answer |
6 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
7 | Correct | 1 ms | 340 KB | n = 3, 29 is a correct answer |
8 | Correct | 1 ms | 340 KB | n = 2, 3 is a correct answer |
9 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
10 | Correct | 1 ms | 340 KB | n = 2, 2000000001 is a correct answer |
11 | Correct | 1 ms | 340 KB | n = 2, 3000000000 is a correct answer |
12 | Correct | 1 ms | 340 KB | n = 3, 3000000000 is a correct answer |
13 | Correct | 0 ms | 340 KB | n = 3, 3000000000 is a correct answer |
14 | Correct | 1 ms | 340 KB | n = 4, 3000000001 is a correct answer |
15 | Correct | 0 ms | 340 KB | n = 4, 4000000000 is a correct answer |
16 | Correct | 0 ms | 340 KB | n = 5, 4000000000 is a correct answer |
17 | Correct | 1 ms | 340 KB | n = 10, 1000000343 is a correct answer |
18 | Correct | 1 ms | 340 KB | n = 10, 3189 is a correct answer |
19 | Correct | 1 ms | 340 KB | n = 10, 7000000000 is a correct answer |
20 | Correct | 1 ms | 340 KB | n = 5, 12 is a correct answer |
21 | Correct | 1 ms | 340 KB | n = 5, 25 is a correct answer |
22 | Correct | 1 ms | 308 KB | n = 2, 122 is a correct answer |
23 | Correct | 1 ms | 340 KB | n = 10, 117 is a correct answer |
24 | Correct | 0 ms | 340 KB | n = 10, 336 is a correct answer |
25 | Correct | 1 ms | 312 KB | n = 10, 438 is a correct answer |
26 | Correct | 1 ms | 340 KB | n = 10, 206 is a correct answer |
27 | Correct | 1 ms | 312 KB | n = 10, 636 is a correct answer |
28 | Correct | 1 ms | 340 KB | n = 4, 2399 is a correct answer |
29 | Correct | 1 ms | 340 KB | n = 10, 10992 is a correct answer |
30 | Incorrect | 1 ms | 312 KB | n = 10, incorrect answer: jury 3112 vs contestant 3174 |
31 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 340 KB | n = 4, 80 is a correct answer |
2 | Correct | 1 ms | 340 KB | n = 9, 110 is a correct answer |
3 | Correct | 0 ms | 340 KB | n = 4, 21 is a correct answer |
4 | Correct | 1 ms | 340 KB | n = 3, 4 is a correct answer |
5 | Correct | 0 ms | 340 KB | n = 2, 62 is a correct answer |
6 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
7 | Correct | 1 ms | 340 KB | n = 3, 29 is a correct answer |
8 | Correct | 1 ms | 340 KB | n = 2, 3 is a correct answer |
9 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
10 | Correct | 1 ms | 340 KB | n = 2, 2000000001 is a correct answer |
11 | Correct | 1 ms | 340 KB | n = 2, 3000000000 is a correct answer |
12 | Correct | 1 ms | 340 KB | n = 3, 3000000000 is a correct answer |
13 | Correct | 0 ms | 340 KB | n = 3, 3000000000 is a correct answer |
14 | Correct | 1 ms | 340 KB | n = 4, 3000000001 is a correct answer |
15 | Correct | 0 ms | 340 KB | n = 4, 4000000000 is a correct answer |
16 | Correct | 0 ms | 340 KB | n = 5, 4000000000 is a correct answer |
17 | Correct | 1 ms | 340 KB | n = 10, 1000000343 is a correct answer |
18 | Correct | 1 ms | 340 KB | n = 10, 3189 is a correct answer |
19 | Correct | 1 ms | 340 KB | n = 10, 7000000000 is a correct answer |
20 | Correct | 1 ms | 340 KB | n = 5, 12 is a correct answer |
21 | Correct | 1 ms | 340 KB | n = 5, 25 is a correct answer |
22 | Correct | 1 ms | 308 KB | n = 2, 122 is a correct answer |
23 | Correct | 1 ms | 340 KB | n = 10, 117 is a correct answer |
24 | Correct | 0 ms | 340 KB | n = 10, 336 is a correct answer |
25 | Correct | 1 ms | 312 KB | n = 10, 438 is a correct answer |
26 | Correct | 1 ms | 340 KB | n = 10, 206 is a correct answer |
27 | Correct | 1 ms | 312 KB | n = 10, 636 is a correct answer |
28 | Correct | 1 ms | 340 KB | n = 4, 2399 is a correct answer |
29 | Correct | 1 ms | 340 KB | n = 10, 10992 is a correct answer |
30 | Incorrect | 1 ms | 312 KB | n = 10, incorrect answer: jury 3112 vs contestant 3174 |
31 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 340 KB | n = 4, 80 is a correct answer |
2 | Correct | 1 ms | 340 KB | n = 9, 110 is a correct answer |
3 | Correct | 0 ms | 340 KB | n = 4, 21 is a correct answer |
4 | Correct | 1 ms | 340 KB | n = 3, 4 is a correct answer |
5 | Correct | 0 ms | 340 KB | n = 2, 62 is a correct answer |
6 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
7 | Correct | 1 ms | 340 KB | n = 3, 29 is a correct answer |
8 | Correct | 1 ms | 340 KB | n = 2, 3 is a correct answer |
9 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
10 | Correct | 1 ms | 340 KB | n = 2, 2000000001 is a correct answer |
11 | Correct | 1 ms | 340 KB | n = 2, 3000000000 is a correct answer |
12 | Correct | 1 ms | 340 KB | n = 3, 3000000000 is a correct answer |
13 | Correct | 0 ms | 340 KB | n = 3, 3000000000 is a correct answer |
14 | Correct | 1 ms | 340 KB | n = 4, 3000000001 is a correct answer |
15 | Correct | 0 ms | 340 KB | n = 4, 4000000000 is a correct answer |
16 | Correct | 0 ms | 340 KB | n = 5, 4000000000 is a correct answer |
17 | Correct | 1 ms | 340 KB | n = 10, 1000000343 is a correct answer |
18 | Correct | 1 ms | 340 KB | n = 10, 3189 is a correct answer |
19 | Correct | 1 ms | 340 KB | n = 10, 7000000000 is a correct answer |
20 | Correct | 1 ms | 340 KB | n = 5, 12 is a correct answer |
21 | Correct | 1 ms | 340 KB | n = 5, 25 is a correct answer |
22 | Correct | 1 ms | 308 KB | n = 2, 122 is a correct answer |
23 | Correct | 1 ms | 340 KB | n = 10, 117 is a correct answer |
24 | Correct | 0 ms | 340 KB | n = 10, 336 is a correct answer |
25 | Correct | 1 ms | 312 KB | n = 10, 438 is a correct answer |
26 | Correct | 1 ms | 340 KB | n = 10, 206 is a correct answer |
27 | Correct | 1 ms | 312 KB | n = 10, 636 is a correct answer |
28 | Correct | 1 ms | 340 KB | n = 4, 2399 is a correct answer |
29 | Correct | 1 ms | 340 KB | n = 10, 10992 is a correct answer |
30 | Incorrect | 1 ms | 312 KB | n = 10, incorrect answer: jury 3112 vs contestant 3174 |
31 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 340 KB | n = 4, 80 is a correct answer |
2 | Correct | 1 ms | 340 KB | n = 9, 110 is a correct answer |
3 | Correct | 0 ms | 340 KB | n = 4, 21 is a correct answer |
4 | Correct | 1 ms | 340 KB | n = 3, 4 is a correct answer |
5 | Correct | 0 ms | 340 KB | n = 2, 62 is a correct answer |
6 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
7 | Correct | 1 ms | 340 KB | n = 3, 29 is a correct answer |
8 | Correct | 1 ms | 340 KB | n = 2, 3 is a correct answer |
9 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
10 | Correct | 1 ms | 340 KB | n = 2, 2000000001 is a correct answer |
11 | Correct | 1 ms | 340 KB | n = 2, 3000000000 is a correct answer |
12 | Correct | 1 ms | 340 KB | n = 3, 3000000000 is a correct answer |
13 | Correct | 0 ms | 340 KB | n = 3, 3000000000 is a correct answer |
14 | Correct | 1 ms | 340 KB | n = 4, 3000000001 is a correct answer |
15 | Correct | 0 ms | 340 KB | n = 4, 4000000000 is a correct answer |
16 | Correct | 0 ms | 340 KB | n = 5, 4000000000 is a correct answer |
17 | Correct | 1 ms | 340 KB | n = 10, 1000000343 is a correct answer |
18 | Correct | 1 ms | 340 KB | n = 10, 3189 is a correct answer |
19 | Correct | 1 ms | 340 KB | n = 10, 7000000000 is a correct answer |
20 | Correct | 1 ms | 340 KB | n = 5, 12 is a correct answer |
21 | Correct | 1 ms | 340 KB | n = 5, 25 is a correct answer |
22 | Correct | 1 ms | 308 KB | n = 2, 122 is a correct answer |
23 | Correct | 1 ms | 340 KB | n = 10, 117 is a correct answer |
24 | Correct | 0 ms | 340 KB | n = 10, 336 is a correct answer |
25 | Correct | 1 ms | 312 KB | n = 10, 438 is a correct answer |
26 | Correct | 1 ms | 340 KB | n = 10, 206 is a correct answer |
27 | Correct | 1 ms | 312 KB | n = 10, 636 is a correct answer |
28 | Correct | 1 ms | 340 KB | n = 4, 2399 is a correct answer |
29 | Correct | 1 ms | 340 KB | n = 10, 10992 is a correct answer |
30 | Incorrect | 1 ms | 312 KB | n = 10, incorrect answer: jury 3112 vs contestant 3174 |
31 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 340 KB | n = 4, 80 is a correct answer |
2 | Correct | 1 ms | 340 KB | n = 9, 110 is a correct answer |
3 | Correct | 0 ms | 340 KB | n = 4, 21 is a correct answer |
4 | Correct | 1 ms | 340 KB | n = 3, 4 is a correct answer |
5 | Correct | 0 ms | 340 KB | n = 2, 62 is a correct answer |
6 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
7 | Correct | 1 ms | 340 KB | n = 3, 29 is a correct answer |
8 | Correct | 1 ms | 340 KB | n = 2, 3 is a correct answer |
9 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
10 | Correct | 1 ms | 340 KB | n = 2, 2000000001 is a correct answer |
11 | Correct | 1 ms | 340 KB | n = 2, 3000000000 is a correct answer |
12 | Correct | 1 ms | 340 KB | n = 3, 3000000000 is a correct answer |
13 | Correct | 0 ms | 340 KB | n = 3, 3000000000 is a correct answer |
14 | Correct | 1 ms | 340 KB | n = 4, 3000000001 is a correct answer |
15 | Correct | 0 ms | 340 KB | n = 4, 4000000000 is a correct answer |
16 | Correct | 0 ms | 340 KB | n = 5, 4000000000 is a correct answer |
17 | Correct | 1 ms | 340 KB | n = 10, 1000000343 is a correct answer |
18 | Correct | 1 ms | 340 KB | n = 10, 3189 is a correct answer |
19 | Correct | 1 ms | 340 KB | n = 10, 7000000000 is a correct answer |
20 | Correct | 1 ms | 340 KB | n = 5, 12 is a correct answer |
21 | Correct | 1 ms | 340 KB | n = 5, 25 is a correct answer |
22 | Correct | 1 ms | 308 KB | n = 2, 122 is a correct answer |
23 | Correct | 1 ms | 340 KB | n = 10, 117 is a correct answer |
24 | Correct | 0 ms | 340 KB | n = 10, 336 is a correct answer |
25 | Correct | 1 ms | 312 KB | n = 10, 438 is a correct answer |
26 | Correct | 1 ms | 340 KB | n = 10, 206 is a correct answer |
27 | Correct | 1 ms | 312 KB | n = 10, 636 is a correct answer |
28 | Correct | 1 ms | 340 KB | n = 4, 2399 is a correct answer |
29 | Correct | 1 ms | 340 KB | n = 10, 10992 is a correct answer |
30 | Incorrect | 1 ms | 312 KB | n = 10, incorrect answer: jury 3112 vs contestant 3174 |
31 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 340 KB | n = 4, 80 is a correct answer |
2 | Correct | 1 ms | 340 KB | n = 9, 110 is a correct answer |
3 | Correct | 0 ms | 340 KB | n = 4, 21 is a correct answer |
4 | Correct | 1 ms | 340 KB | n = 3, 4 is a correct answer |
5 | Correct | 0 ms | 340 KB | n = 2, 62 is a correct answer |
6 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
7 | Correct | 1 ms | 340 KB | n = 3, 29 is a correct answer |
8 | Correct | 1 ms | 340 KB | n = 2, 3 is a correct answer |
9 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
10 | Correct | 1 ms | 340 KB | n = 2, 2000000001 is a correct answer |
11 | Correct | 1 ms | 340 KB | n = 2, 3000000000 is a correct answer |
12 | Correct | 1 ms | 340 KB | n = 3, 3000000000 is a correct answer |
13 | Correct | 0 ms | 340 KB | n = 3, 3000000000 is a correct answer |
14 | Correct | 1 ms | 340 KB | n = 4, 3000000001 is a correct answer |
15 | Correct | 0 ms | 340 KB | n = 4, 4000000000 is a correct answer |
16 | Correct | 0 ms | 340 KB | n = 5, 4000000000 is a correct answer |
17 | Correct | 1 ms | 340 KB | n = 10, 1000000343 is a correct answer |
18 | Correct | 1 ms | 340 KB | n = 10, 3189 is a correct answer |
19 | Correct | 1 ms | 340 KB | n = 10, 7000000000 is a correct answer |
20 | Correct | 1 ms | 340 KB | n = 5, 12 is a correct answer |
21 | Correct | 1 ms | 340 KB | n = 5, 25 is a correct answer |
22 | Correct | 1 ms | 308 KB | n = 2, 122 is a correct answer |
23 | Correct | 1 ms | 340 KB | n = 10, 117 is a correct answer |
24 | Correct | 0 ms | 340 KB | n = 10, 336 is a correct answer |
25 | Correct | 1 ms | 312 KB | n = 10, 438 is a correct answer |
26 | Correct | 1 ms | 340 KB | n = 10, 206 is a correct answer |
27 | Correct | 1 ms | 312 KB | n = 10, 636 is a correct answer |
28 | Correct | 1 ms | 340 KB | n = 4, 2399 is a correct answer |
29 | Correct | 1 ms | 340 KB | n = 10, 10992 is a correct answer |
30 | Incorrect | 1 ms | 312 KB | n = 10, incorrect answer: jury 3112 vs contestant 3174 |
31 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 340 KB | n = 4, 80 is a correct answer |
2 | Correct | 1 ms | 340 KB | n = 9, 110 is a correct answer |
3 | Correct | 0 ms | 340 KB | n = 4, 21 is a correct answer |
4 | Correct | 1 ms | 340 KB | n = 3, 4 is a correct answer |
5 | Correct | 0 ms | 340 KB | n = 2, 62 is a correct answer |
6 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
7 | Correct | 1 ms | 340 KB | n = 3, 29 is a correct answer |
8 | Correct | 1 ms | 340 KB | n = 2, 3 is a correct answer |
9 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
10 | Correct | 1 ms | 340 KB | n = 2, 2000000001 is a correct answer |
11 | Correct | 1 ms | 340 KB | n = 2, 3000000000 is a correct answer |
12 | Correct | 1 ms | 340 KB | n = 3, 3000000000 is a correct answer |
13 | Correct | 0 ms | 340 KB | n = 3, 3000000000 is a correct answer |
14 | Correct | 1 ms | 340 KB | n = 4, 3000000001 is a correct answer |
15 | Correct | 0 ms | 340 KB | n = 4, 4000000000 is a correct answer |
16 | Correct | 0 ms | 340 KB | n = 5, 4000000000 is a correct answer |
17 | Correct | 1 ms | 340 KB | n = 10, 1000000343 is a correct answer |
18 | Correct | 1 ms | 340 KB | n = 10, 3189 is a correct answer |
19 | Correct | 1 ms | 340 KB | n = 10, 7000000000 is a correct answer |
20 | Correct | 1 ms | 340 KB | n = 5, 12 is a correct answer |
21 | Correct | 1 ms | 340 KB | n = 5, 25 is a correct answer |
22 | Correct | 1 ms | 308 KB | n = 2, 122 is a correct answer |
23 | Correct | 1 ms | 340 KB | n = 10, 117 is a correct answer |
24 | Correct | 0 ms | 340 KB | n = 10, 336 is a correct answer |
25 | Correct | 1 ms | 312 KB | n = 10, 438 is a correct answer |
26 | Correct | 1 ms | 340 KB | n = 10, 206 is a correct answer |
27 | Correct | 1 ms | 312 KB | n = 10, 636 is a correct answer |
28 | Correct | 1 ms | 340 KB | n = 4, 2399 is a correct answer |
29 | Correct | 1 ms | 340 KB | n = 10, 10992 is a correct answer |
30 | Incorrect | 1 ms | 312 KB | n = 10, incorrect answer: jury 3112 vs contestant 3174 |
31 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 1 ms | 340 KB | n = 4, 80 is a correct answer |
2 | Correct | 1 ms | 340 KB | n = 9, 110 is a correct answer |
3 | Correct | 0 ms | 340 KB | n = 4, 21 is a correct answer |
4 | Correct | 1 ms | 340 KB | n = 3, 4 is a correct answer |
5 | Correct | 0 ms | 340 KB | n = 2, 62 is a correct answer |
6 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
7 | Correct | 1 ms | 340 KB | n = 3, 29 is a correct answer |
8 | Correct | 1 ms | 340 KB | n = 2, 3 is a correct answer |
9 | Correct | 0 ms | 340 KB | n = 2, 3 is a correct answer |
10 | Correct | 1 ms | 340 KB | n = 2, 2000000001 is a correct answer |
11 | Correct | 1 ms | 340 KB | n = 2, 3000000000 is a correct answer |
12 | Correct | 1 ms | 340 KB | n = 3, 3000000000 is a correct answer |
13 | Correct | 0 ms | 340 KB | n = 3, 3000000000 is a correct answer |
14 | Correct | 1 ms | 340 KB | n = 4, 3000000001 is a correct answer |
15 | Correct | 0 ms | 340 KB | n = 4, 4000000000 is a correct answer |
16 | Correct | 0 ms | 340 KB | n = 5, 4000000000 is a correct answer |
17 | Correct | 1 ms | 340 KB | n = 10, 1000000343 is a correct answer |
18 | Correct | 1 ms | 340 KB | n = 10, 3189 is a correct answer |
19 | Correct | 1 ms | 340 KB | n = 10, 7000000000 is a correct answer |
20 | Correct | 1 ms | 340 KB | n = 5, 12 is a correct answer |
21 | Correct | 1 ms | 340 KB | n = 5, 25 is a correct answer |
22 | Correct | 1 ms | 308 KB | n = 2, 122 is a correct answer |
23 | Correct | 1 ms | 340 KB | n = 10, 117 is a correct answer |
24 | Correct | 0 ms | 340 KB | n = 10, 336 is a correct answer |
25 | Correct | 1 ms | 312 KB | n = 10, 438 is a correct answer |
26 | Correct | 1 ms | 340 KB | n = 10, 206 is a correct answer |
27 | Correct | 1 ms | 312 KB | n = 10, 636 is a correct answer |
28 | Correct | 1 ms | 340 KB | n = 4, 2399 is a correct answer |
29 | Correct | 1 ms | 340 KB | n = 10, 10992 is a correct answer |
30 | Incorrect | 1 ms | 312 KB | n = 10, incorrect answer: jury 3112 vs contestant 3174 |
31 | Halted | 0 ms | 0 KB | - |