#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#pragma comment(linker, "/stack:200000000")
#pragma GCC optimize("Ofast")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,avx2,tune=native")
#define fast ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);
#define file(s) freopen(s".in", "r", stdin);freopen(s".out", "w", stdout);
#define nano chrono::steady_clock::now().time_since_epoch().count()
#define uid uniform_int_distribution<int>
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(),v.rend()
#define pb push_back
#define sz size()
#define ft first
#define sd second
using namespace std;
typedef long long ll;
typedef pair<ll, ll> pll;
typedef unsigned long long ull;
const int N = 2e5 + 10;
const int M = 2e3 + 5;
const ll inf = 1e15;
const ll mod = 998244353;
const double Pi = acos(-1);
ll binpow(ll x, ll ti) { ll res = 1;while (ti){if(ti & 1)res *= x;x *= x;ti >>= 1; x %= mod; res %= mod;} return res;}
ll binmul(ll x, ll ti) { ll res = 0;while (ti){if(ti & 1)res += x;x += x;ti >>= 1; x %= mod; res %= mod;} return res;}
ll random(ll l, ll r) { mt19937 rnd(nano); uid dist(l, r); return dist(rnd); }
ll nok(ll a, ll b) { return (a*b)/__gcd(abs(a),abs(b)) * (a*b > 0 ? 1 : -1); }
bool odd(ll n) { return (n % 2 == 1); }
bool even(ll n) { return (n % 2 == 0); }
int n, a[N], dis[2005][2005], d[N];
vector <int> g[N];
bool ok = 1;
void init(int N, vector <int> H) {
n = N;
for (int i = 1; i <= n; ++ i) {
a[i] = H[i - 1];
if (a[i] != i) {
ok = 0;
}
}
deque <int> d;
d.push_back(0);
a[0] = 1e9;
for (int i = 1; i <= n; ++ i) {
while (d.sz && a[d.back()] <= a[i]) d.pop_back();
if (d.back() != 0) {
g[i].pb(d.back());
}
d.push_back(i);
}
d.clear();
a[n + 1] = 1e9;
d.push_back(n + 1);
for (int i = n; i >= 1; -- i) {
while (d.sz && a[d.back()] <= a[i]) d.pop_back();
if (d.back() != n + 1) {
g[i].pb(d.back());
}
d.push_back(i);
}
if (n <= 2000) {
for (int i = 1; i <= n; ++ i) {
for (int j = 1; j <= n; ++ j) dis[i][j] = 1e9;
queue <int> q;
q.push(i);
dis[i][i] = 0;
while (q.sz) {
int v = q.front();
q.pop();
for (auto to : g[v]) {
if (dis[i][to] > dis[i][v] + 1) {
dis[i][to] = dis[i][v] + 1;
q.push(to);
}
}
}
}
}
}
int minimum_jumps(int A, int B, int C, int D) {
int ans = 1e9;
++ A; ++ B; ++ C; ++ D;
if (ok) return C - B;
if (n <= 2000) {
for (int i = A; i <= B; ++ i) {
for (int j = C; j <= D; ++ j) {
ans = min(ans, dis[i][j]);
}
}
} else {
queue <ll> q;
for (int i = 1; i <= n; ++ i) d[i] = 1e9;
for (int i = A; i <= B; ++ i) q.push(i), d[i] = 0;
while (q.sz) {
int v = q.front();
q.pop();
for (auto to : g[v]) {
if (d[to] > d[v] + 1) {
d[to] = d[v] + 1;
q.push(to);
}
}
}
for (int i = C; i <= D; ++ i) ans = min(ans, d[i]);
}
return (ans == 1e9 ? -1 : ans);
}
//signed main() {
// init(7, {3, 2, 1, 6, 4, 5, 7});
// cout << minimum_jumps(0, 1, 2, 2);
//}
Compilation message
jumps.cpp:5: warning: ignoring '#pragma comment ' [-Wunknown-pragmas]
5 | #pragma comment(linker, "/stack:200000000")
|
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
3 ms |
4944 KB |
Output is correct |
2 |
Correct |
3 ms |
4944 KB |
Output is correct |
3 |
Correct |
69 ms |
12420 KB |
Output is correct |
4 |
Correct |
763 ms |
14408 KB |
Output is correct |
5 |
Correct |
674 ms |
9756 KB |
Output is correct |
6 |
Correct |
750 ms |
14336 KB |
Output is correct |
7 |
Correct |
654 ms |
11396 KB |
Output is correct |
8 |
Correct |
797 ms |
14340 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
3 ms |
4944 KB |
Output is correct |
2 |
Correct |
3 ms |
4944 KB |
Output is correct |
3 |
Correct |
2 ms |
4944 KB |
Output is correct |
4 |
Correct |
2 ms |
4944 KB |
Output is correct |
5 |
Correct |
6 ms |
5072 KB |
Output is correct |
6 |
Correct |
5 ms |
5968 KB |
Output is correct |
7 |
Correct |
5 ms |
5840 KB |
Output is correct |
8 |
Correct |
5 ms |
5984 KB |
Output is correct |
9 |
Correct |
4 ms |
5712 KB |
Output is correct |
10 |
Correct |
6 ms |
5968 KB |
Output is correct |
11 |
Correct |
5 ms |
5968 KB |
Output is correct |
12 |
Correct |
6 ms |
5968 KB |
Output is correct |
13 |
Correct |
5 ms |
5968 KB |
Output is correct |
14 |
Correct |
6 ms |
5968 KB |
Output is correct |
15 |
Correct |
5 ms |
5968 KB |
Output is correct |
16 |
Correct |
5 ms |
5968 KB |
Output is correct |
17 |
Correct |
5 ms |
5968 KB |
Output is correct |
18 |
Correct |
3 ms |
4944 KB |
Output is correct |
19 |
Correct |
3 ms |
5072 KB |
Output is correct |
20 |
Correct |
6 ms |
5968 KB |
Output is correct |
21 |
Correct |
8 ms |
5968 KB |
Output is correct |
22 |
Correct |
6 ms |
5924 KB |
Output is correct |
23 |
Correct |
6 ms |
5968 KB |
Output is correct |
24 |
Correct |
6 ms |
5968 KB |
Output is correct |
25 |
Correct |
3 ms |
4944 KB |
Output is correct |
26 |
Correct |
3 ms |
4944 KB |
Output is correct |
27 |
Correct |
5 ms |
4944 KB |
Output is correct |
28 |
Correct |
5 ms |
5968 KB |
Output is correct |
29 |
Correct |
6 ms |
5968 KB |
Output is correct |
30 |
Correct |
5 ms |
5968 KB |
Output is correct |
31 |
Correct |
5 ms |
5968 KB |
Output is correct |
32 |
Correct |
7 ms |
5960 KB |
Output is correct |
33 |
Correct |
3 ms |
4944 KB |
Output is correct |
34 |
Correct |
3 ms |
5760 KB |
Output is correct |
35 |
Correct |
3 ms |
5968 KB |
Output is correct |
36 |
Correct |
4 ms |
5968 KB |
Output is correct |
37 |
Correct |
5 ms |
5968 KB |
Output is correct |
38 |
Correct |
4 ms |
5968 KB |
Output is correct |
39 |
Correct |
4 ms |
5968 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
3 ms |
4944 KB |
Output is correct |
2 |
Correct |
3 ms |
4944 KB |
Output is correct |
3 |
Correct |
2 ms |
4944 KB |
Output is correct |
4 |
Correct |
2 ms |
4944 KB |
Output is correct |
5 |
Correct |
6 ms |
5072 KB |
Output is correct |
6 |
Correct |
5 ms |
5968 KB |
Output is correct |
7 |
Correct |
5 ms |
5840 KB |
Output is correct |
8 |
Correct |
5 ms |
5984 KB |
Output is correct |
9 |
Correct |
4 ms |
5712 KB |
Output is correct |
10 |
Correct |
6 ms |
5968 KB |
Output is correct |
11 |
Correct |
5 ms |
5968 KB |
Output is correct |
12 |
Correct |
6 ms |
5968 KB |
Output is correct |
13 |
Correct |
5 ms |
5968 KB |
Output is correct |
14 |
Correct |
6 ms |
5968 KB |
Output is correct |
15 |
Correct |
5 ms |
5968 KB |
Output is correct |
16 |
Correct |
5 ms |
5968 KB |
Output is correct |
17 |
Correct |
5 ms |
5968 KB |
Output is correct |
18 |
Correct |
3 ms |
4944 KB |
Output is correct |
19 |
Correct |
3 ms |
5072 KB |
Output is correct |
20 |
Correct |
6 ms |
5968 KB |
Output is correct |
21 |
Correct |
8 ms |
5968 KB |
Output is correct |
22 |
Correct |
6 ms |
5924 KB |
Output is correct |
23 |
Correct |
6 ms |
5968 KB |
Output is correct |
24 |
Correct |
6 ms |
5968 KB |
Output is correct |
25 |
Correct |
3 ms |
4944 KB |
Output is correct |
26 |
Correct |
3 ms |
4944 KB |
Output is correct |
27 |
Correct |
5 ms |
4944 KB |
Output is correct |
28 |
Correct |
5 ms |
5968 KB |
Output is correct |
29 |
Correct |
6 ms |
5968 KB |
Output is correct |
30 |
Correct |
5 ms |
5968 KB |
Output is correct |
31 |
Correct |
5 ms |
5968 KB |
Output is correct |
32 |
Correct |
7 ms |
5960 KB |
Output is correct |
33 |
Correct |
3 ms |
4944 KB |
Output is correct |
34 |
Correct |
3 ms |
5760 KB |
Output is correct |
35 |
Correct |
3 ms |
5968 KB |
Output is correct |
36 |
Correct |
4 ms |
5968 KB |
Output is correct |
37 |
Correct |
5 ms |
5968 KB |
Output is correct |
38 |
Correct |
4 ms |
5968 KB |
Output is correct |
39 |
Correct |
4 ms |
5968 KB |
Output is correct |
40 |
Correct |
2 ms |
4944 KB |
Output is correct |
41 |
Correct |
2 ms |
4944 KB |
Output is correct |
42 |
Correct |
3 ms |
4944 KB |
Output is correct |
43 |
Correct |
3 ms |
4944 KB |
Output is correct |
44 |
Correct |
4 ms |
5072 KB |
Output is correct |
45 |
Correct |
5 ms |
5968 KB |
Output is correct |
46 |
Correct |
5 ms |
5840 KB |
Output is correct |
47 |
Correct |
5 ms |
5968 KB |
Output is correct |
48 |
Correct |
4 ms |
5712 KB |
Output is correct |
49 |
Correct |
5 ms |
5860 KB |
Output is correct |
50 |
Correct |
6 ms |
5968 KB |
Output is correct |
51 |
Correct |
7 ms |
5968 KB |
Output is correct |
52 |
Correct |
7 ms |
5940 KB |
Output is correct |
53 |
Correct |
8 ms |
5968 KB |
Output is correct |
54 |
Correct |
7 ms |
5968 KB |
Output is correct |
55 |
Correct |
7 ms |
5968 KB |
Output is correct |
56 |
Correct |
5 ms |
5968 KB |
Output is correct |
57 |
Correct |
3 ms |
5968 KB |
Output is correct |
58 |
Correct |
57 ms |
18384 KB |
Output is correct |
59 |
Correct |
110 ms |
20776 KB |
Output is correct |
60 |
Correct |
14 ms |
10960 KB |
Output is correct |
61 |
Correct |
103 ms |
20688 KB |
Output is correct |
62 |
Correct |
16 ms |
5968 KB |
Output is correct |
63 |
Correct |
93 ms |
20704 KB |
Output is correct |
64 |
Correct |
47 ms |
20696 KB |
Output is correct |
65 |
Correct |
117 ms |
20700 KB |
Output is correct |
66 |
Correct |
109 ms |
20744 KB |
Output is correct |
67 |
Correct |
115 ms |
20764 KB |
Output is correct |
68 |
Correct |
122 ms |
20684 KB |
Output is correct |
69 |
Correct |
80 ms |
20728 KB |
Output is correct |
70 |
Correct |
61 ms |
20680 KB |
Output is correct |
71 |
Correct |
3 ms |
4944 KB |
Output is correct |
72 |
Correct |
3 ms |
5072 KB |
Output is correct |
73 |
Correct |
6 ms |
5968 KB |
Output is correct |
74 |
Correct |
5 ms |
5948 KB |
Output is correct |
75 |
Correct |
5 ms |
5968 KB |
Output is correct |
76 |
Correct |
6 ms |
5884 KB |
Output is correct |
77 |
Correct |
5 ms |
5968 KB |
Output is correct |
78 |
Correct |
3 ms |
4944 KB |
Output is correct |
79 |
Correct |
3 ms |
4944 KB |
Output is correct |
80 |
Correct |
4 ms |
4944 KB |
Output is correct |
81 |
Correct |
5 ms |
5968 KB |
Output is correct |
82 |
Correct |
5 ms |
5968 KB |
Output is correct |
83 |
Correct |
4 ms |
5968 KB |
Output is correct |
84 |
Correct |
5 ms |
5968 KB |
Output is correct |
85 |
Correct |
7 ms |
6048 KB |
Output is correct |
86 |
Correct |
3 ms |
4944 KB |
Output is correct |
87 |
Correct |
4 ms |
5840 KB |
Output is correct |
88 |
Correct |
4 ms |
5968 KB |
Output is correct |
89 |
Correct |
4 ms |
5968 KB |
Output is correct |
90 |
Correct |
4 ms |
5968 KB |
Output is correct |
91 |
Correct |
4 ms |
5968 KB |
Output is correct |
92 |
Correct |
4 ms |
5968 KB |
Output is correct |
93 |
Correct |
3 ms |
5968 KB |
Output is correct |
94 |
Correct |
6 ms |
6096 KB |
Output is correct |
95 |
Correct |
35 ms |
20688 KB |
Output is correct |
96 |
Correct |
49 ms |
20760 KB |
Output is correct |
97 |
Correct |
48 ms |
20784 KB |
Output is correct |
98 |
Correct |
58 ms |
20700 KB |
Output is correct |
99 |
Correct |
56 ms |
20768 KB |
Output is correct |
100 |
Correct |
3 ms |
5968 KB |
Output is correct |
101 |
Correct |
6 ms |
10192 KB |
Output is correct |
102 |
Correct |
18 ms |
20816 KB |
Output is correct |
103 |
Correct |
48 ms |
20700 KB |
Output is correct |
104 |
Correct |
28 ms |
20716 KB |
Output is correct |
105 |
Correct |
44 ms |
20672 KB |
Output is correct |
106 |
Correct |
51 ms |
20708 KB |
Output is correct |
107 |
Correct |
3 ms |
5968 KB |
Output is correct |
108 |
Correct |
7 ms |
12112 KB |
Output is correct |
109 |
Correct |
11 ms |
20688 KB |
Output is correct |
110 |
Correct |
31 ms |
20688 KB |
Output is correct |
111 |
Correct |
13 ms |
20688 KB |
Output is correct |
112 |
Correct |
32 ms |
20716 KB |
Output is correct |
113 |
Correct |
38 ms |
20744 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
3 ms |
4944 KB |
Output is correct |
2 |
Correct |
3 ms |
4944 KB |
Output is correct |
3 |
Correct |
2 ms |
4944 KB |
Output is correct |
4 |
Correct |
3 ms |
4944 KB |
Output is correct |
5 |
Correct |
40 ms |
12556 KB |
Output is correct |
6 |
Correct |
50 ms |
14200 KB |
Output is correct |
7 |
Correct |
24 ms |
9400 KB |
Output is correct |
8 |
Correct |
69 ms |
15160 KB |
Output is correct |
9 |
Correct |
10 ms |
6396 KB |
Output is correct |
10 |
Correct |
46 ms |
14056 KB |
Output is correct |
11 |
Correct |
35 ms |
14352 KB |
Output is correct |
12 |
Correct |
66 ms |
14512 KB |
Output is correct |
13 |
Correct |
44 ms |
14228 KB |
Output is correct |
14 |
Correct |
45 ms |
13964 KB |
Output is correct |
15 |
Correct |
56 ms |
14352 KB |
Output is correct |
16 |
Correct |
50 ms |
15108 KB |
Output is correct |
17 |
Correct |
67 ms |
15084 KB |
Output is correct |
18 |
Correct |
3 ms |
4972 KB |
Output is correct |
19 |
Correct |
3 ms |
5840 KB |
Output is correct |
20 |
Correct |
4 ms |
5968 KB |
Output is correct |
21 |
Correct |
3 ms |
5968 KB |
Output is correct |
22 |
Correct |
4 ms |
5968 KB |
Output is correct |
23 |
Correct |
4 ms |
5968 KB |
Output is correct |
24 |
Correct |
4 ms |
5948 KB |
Output is correct |
25 |
Correct |
3 ms |
5940 KB |
Output is correct |
26 |
Correct |
7 ms |
12112 KB |
Output is correct |
27 |
Correct |
11 ms |
20688 KB |
Output is correct |
28 |
Correct |
33 ms |
20664 KB |
Output is correct |
29 |
Correct |
11 ms |
20688 KB |
Output is correct |
30 |
Correct |
34 ms |
20768 KB |
Output is correct |
31 |
Correct |
41 ms |
20712 KB |
Output is correct |
32 |
Correct |
3 ms |
4944 KB |
Output is correct |
33 |
Correct |
47 ms |
13488 KB |
Output is correct |
34 |
Correct |
48 ms |
14128 KB |
Output is correct |
35 |
Correct |
45 ms |
14524 KB |
Output is correct |
36 |
Correct |
53 ms |
13864 KB |
Output is correct |
37 |
Correct |
47 ms |
14156 KB |
Output is correct |
38 |
Correct |
42 ms |
15212 KB |
Output is correct |
39 |
Correct |
3 ms |
4944 KB |
Output is correct |
40 |
Correct |
28 ms |
9992 KB |
Output is correct |
41 |
Correct |
47 ms |
13596 KB |
Output is correct |
42 |
Correct |
42 ms |
14236 KB |
Output is correct |
43 |
Correct |
46 ms |
13536 KB |
Output is correct |
44 |
Correct |
56 ms |
13972 KB |
Output is correct |
45 |
Correct |
47 ms |
14484 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
2 ms |
4944 KB |
Output is correct |
2 |
Correct |
3 ms |
4944 KB |
Output is correct |
3 |
Correct |
3 ms |
4944 KB |
Output is correct |
4 |
Correct |
701 ms |
8940 KB |
Output is correct |
5 |
Execution timed out |
4026 ms |
13688 KB |
Time limit exceeded |
6 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
2 ms |
4944 KB |
Output is correct |
2 |
Correct |
3 ms |
4944 KB |
Output is correct |
3 |
Correct |
3 ms |
4944 KB |
Output is correct |
4 |
Correct |
701 ms |
8940 KB |
Output is correct |
5 |
Execution timed out |
4026 ms |
13688 KB |
Time limit exceeded |
6 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
3 ms |
4944 KB |
Output is correct |
2 |
Correct |
3 ms |
4944 KB |
Output is correct |
3 |
Correct |
69 ms |
12420 KB |
Output is correct |
4 |
Correct |
763 ms |
14408 KB |
Output is correct |
5 |
Correct |
674 ms |
9756 KB |
Output is correct |
6 |
Correct |
750 ms |
14336 KB |
Output is correct |
7 |
Correct |
654 ms |
11396 KB |
Output is correct |
8 |
Correct |
797 ms |
14340 KB |
Output is correct |
9 |
Correct |
3 ms |
4944 KB |
Output is correct |
10 |
Correct |
3 ms |
4944 KB |
Output is correct |
11 |
Correct |
2 ms |
4944 KB |
Output is correct |
12 |
Correct |
2 ms |
4944 KB |
Output is correct |
13 |
Correct |
6 ms |
5072 KB |
Output is correct |
14 |
Correct |
5 ms |
5968 KB |
Output is correct |
15 |
Correct |
5 ms |
5840 KB |
Output is correct |
16 |
Correct |
5 ms |
5984 KB |
Output is correct |
17 |
Correct |
4 ms |
5712 KB |
Output is correct |
18 |
Correct |
6 ms |
5968 KB |
Output is correct |
19 |
Correct |
5 ms |
5968 KB |
Output is correct |
20 |
Correct |
6 ms |
5968 KB |
Output is correct |
21 |
Correct |
5 ms |
5968 KB |
Output is correct |
22 |
Correct |
6 ms |
5968 KB |
Output is correct |
23 |
Correct |
5 ms |
5968 KB |
Output is correct |
24 |
Correct |
5 ms |
5968 KB |
Output is correct |
25 |
Correct |
5 ms |
5968 KB |
Output is correct |
26 |
Correct |
3 ms |
4944 KB |
Output is correct |
27 |
Correct |
3 ms |
5072 KB |
Output is correct |
28 |
Correct |
6 ms |
5968 KB |
Output is correct |
29 |
Correct |
8 ms |
5968 KB |
Output is correct |
30 |
Correct |
6 ms |
5924 KB |
Output is correct |
31 |
Correct |
6 ms |
5968 KB |
Output is correct |
32 |
Correct |
6 ms |
5968 KB |
Output is correct |
33 |
Correct |
3 ms |
4944 KB |
Output is correct |
34 |
Correct |
3 ms |
4944 KB |
Output is correct |
35 |
Correct |
5 ms |
4944 KB |
Output is correct |
36 |
Correct |
5 ms |
5968 KB |
Output is correct |
37 |
Correct |
6 ms |
5968 KB |
Output is correct |
38 |
Correct |
5 ms |
5968 KB |
Output is correct |
39 |
Correct |
5 ms |
5968 KB |
Output is correct |
40 |
Correct |
7 ms |
5960 KB |
Output is correct |
41 |
Correct |
3 ms |
4944 KB |
Output is correct |
42 |
Correct |
3 ms |
5760 KB |
Output is correct |
43 |
Correct |
3 ms |
5968 KB |
Output is correct |
44 |
Correct |
4 ms |
5968 KB |
Output is correct |
45 |
Correct |
5 ms |
5968 KB |
Output is correct |
46 |
Correct |
4 ms |
5968 KB |
Output is correct |
47 |
Correct |
4 ms |
5968 KB |
Output is correct |
48 |
Correct |
2 ms |
4944 KB |
Output is correct |
49 |
Correct |
2 ms |
4944 KB |
Output is correct |
50 |
Correct |
3 ms |
4944 KB |
Output is correct |
51 |
Correct |
3 ms |
4944 KB |
Output is correct |
52 |
Correct |
4 ms |
5072 KB |
Output is correct |
53 |
Correct |
5 ms |
5968 KB |
Output is correct |
54 |
Correct |
5 ms |
5840 KB |
Output is correct |
55 |
Correct |
5 ms |
5968 KB |
Output is correct |
56 |
Correct |
4 ms |
5712 KB |
Output is correct |
57 |
Correct |
5 ms |
5860 KB |
Output is correct |
58 |
Correct |
6 ms |
5968 KB |
Output is correct |
59 |
Correct |
7 ms |
5968 KB |
Output is correct |
60 |
Correct |
7 ms |
5940 KB |
Output is correct |
61 |
Correct |
8 ms |
5968 KB |
Output is correct |
62 |
Correct |
7 ms |
5968 KB |
Output is correct |
63 |
Correct |
7 ms |
5968 KB |
Output is correct |
64 |
Correct |
5 ms |
5968 KB |
Output is correct |
65 |
Correct |
3 ms |
5968 KB |
Output is correct |
66 |
Correct |
57 ms |
18384 KB |
Output is correct |
67 |
Correct |
110 ms |
20776 KB |
Output is correct |
68 |
Correct |
14 ms |
10960 KB |
Output is correct |
69 |
Correct |
103 ms |
20688 KB |
Output is correct |
70 |
Correct |
16 ms |
5968 KB |
Output is correct |
71 |
Correct |
93 ms |
20704 KB |
Output is correct |
72 |
Correct |
47 ms |
20696 KB |
Output is correct |
73 |
Correct |
117 ms |
20700 KB |
Output is correct |
74 |
Correct |
109 ms |
20744 KB |
Output is correct |
75 |
Correct |
115 ms |
20764 KB |
Output is correct |
76 |
Correct |
122 ms |
20684 KB |
Output is correct |
77 |
Correct |
80 ms |
20728 KB |
Output is correct |
78 |
Correct |
61 ms |
20680 KB |
Output is correct |
79 |
Correct |
3 ms |
4944 KB |
Output is correct |
80 |
Correct |
3 ms |
5072 KB |
Output is correct |
81 |
Correct |
6 ms |
5968 KB |
Output is correct |
82 |
Correct |
5 ms |
5948 KB |
Output is correct |
83 |
Correct |
5 ms |
5968 KB |
Output is correct |
84 |
Correct |
6 ms |
5884 KB |
Output is correct |
85 |
Correct |
5 ms |
5968 KB |
Output is correct |
86 |
Correct |
3 ms |
4944 KB |
Output is correct |
87 |
Correct |
3 ms |
4944 KB |
Output is correct |
88 |
Correct |
4 ms |
4944 KB |
Output is correct |
89 |
Correct |
5 ms |
5968 KB |
Output is correct |
90 |
Correct |
5 ms |
5968 KB |
Output is correct |
91 |
Correct |
4 ms |
5968 KB |
Output is correct |
92 |
Correct |
5 ms |
5968 KB |
Output is correct |
93 |
Correct |
7 ms |
6048 KB |
Output is correct |
94 |
Correct |
3 ms |
4944 KB |
Output is correct |
95 |
Correct |
4 ms |
5840 KB |
Output is correct |
96 |
Correct |
4 ms |
5968 KB |
Output is correct |
97 |
Correct |
4 ms |
5968 KB |
Output is correct |
98 |
Correct |
4 ms |
5968 KB |
Output is correct |
99 |
Correct |
4 ms |
5968 KB |
Output is correct |
100 |
Correct |
4 ms |
5968 KB |
Output is correct |
101 |
Correct |
3 ms |
5968 KB |
Output is correct |
102 |
Correct |
6 ms |
6096 KB |
Output is correct |
103 |
Correct |
35 ms |
20688 KB |
Output is correct |
104 |
Correct |
49 ms |
20760 KB |
Output is correct |
105 |
Correct |
48 ms |
20784 KB |
Output is correct |
106 |
Correct |
58 ms |
20700 KB |
Output is correct |
107 |
Correct |
56 ms |
20768 KB |
Output is correct |
108 |
Correct |
3 ms |
5968 KB |
Output is correct |
109 |
Correct |
6 ms |
10192 KB |
Output is correct |
110 |
Correct |
18 ms |
20816 KB |
Output is correct |
111 |
Correct |
48 ms |
20700 KB |
Output is correct |
112 |
Correct |
28 ms |
20716 KB |
Output is correct |
113 |
Correct |
44 ms |
20672 KB |
Output is correct |
114 |
Correct |
51 ms |
20708 KB |
Output is correct |
115 |
Correct |
3 ms |
5968 KB |
Output is correct |
116 |
Correct |
7 ms |
12112 KB |
Output is correct |
117 |
Correct |
11 ms |
20688 KB |
Output is correct |
118 |
Correct |
31 ms |
20688 KB |
Output is correct |
119 |
Correct |
13 ms |
20688 KB |
Output is correct |
120 |
Correct |
32 ms |
20716 KB |
Output is correct |
121 |
Correct |
38 ms |
20744 KB |
Output is correct |
122 |
Correct |
3 ms |
4944 KB |
Output is correct |
123 |
Correct |
3 ms |
4944 KB |
Output is correct |
124 |
Correct |
2 ms |
4944 KB |
Output is correct |
125 |
Correct |
3 ms |
4944 KB |
Output is correct |
126 |
Correct |
40 ms |
12556 KB |
Output is correct |
127 |
Correct |
50 ms |
14200 KB |
Output is correct |
128 |
Correct |
24 ms |
9400 KB |
Output is correct |
129 |
Correct |
69 ms |
15160 KB |
Output is correct |
130 |
Correct |
10 ms |
6396 KB |
Output is correct |
131 |
Correct |
46 ms |
14056 KB |
Output is correct |
132 |
Correct |
35 ms |
14352 KB |
Output is correct |
133 |
Correct |
66 ms |
14512 KB |
Output is correct |
134 |
Correct |
44 ms |
14228 KB |
Output is correct |
135 |
Correct |
45 ms |
13964 KB |
Output is correct |
136 |
Correct |
56 ms |
14352 KB |
Output is correct |
137 |
Correct |
50 ms |
15108 KB |
Output is correct |
138 |
Correct |
67 ms |
15084 KB |
Output is correct |
139 |
Correct |
3 ms |
4972 KB |
Output is correct |
140 |
Correct |
3 ms |
5840 KB |
Output is correct |
141 |
Correct |
4 ms |
5968 KB |
Output is correct |
142 |
Correct |
3 ms |
5968 KB |
Output is correct |
143 |
Correct |
4 ms |
5968 KB |
Output is correct |
144 |
Correct |
4 ms |
5968 KB |
Output is correct |
145 |
Correct |
4 ms |
5948 KB |
Output is correct |
146 |
Correct |
3 ms |
5940 KB |
Output is correct |
147 |
Correct |
7 ms |
12112 KB |
Output is correct |
148 |
Correct |
11 ms |
20688 KB |
Output is correct |
149 |
Correct |
33 ms |
20664 KB |
Output is correct |
150 |
Correct |
11 ms |
20688 KB |
Output is correct |
151 |
Correct |
34 ms |
20768 KB |
Output is correct |
152 |
Correct |
41 ms |
20712 KB |
Output is correct |
153 |
Correct |
3 ms |
4944 KB |
Output is correct |
154 |
Correct |
47 ms |
13488 KB |
Output is correct |
155 |
Correct |
48 ms |
14128 KB |
Output is correct |
156 |
Correct |
45 ms |
14524 KB |
Output is correct |
157 |
Correct |
53 ms |
13864 KB |
Output is correct |
158 |
Correct |
47 ms |
14156 KB |
Output is correct |
159 |
Correct |
42 ms |
15212 KB |
Output is correct |
160 |
Correct |
3 ms |
4944 KB |
Output is correct |
161 |
Correct |
28 ms |
9992 KB |
Output is correct |
162 |
Correct |
47 ms |
13596 KB |
Output is correct |
163 |
Correct |
42 ms |
14236 KB |
Output is correct |
164 |
Correct |
46 ms |
13536 KB |
Output is correct |
165 |
Correct |
56 ms |
13972 KB |
Output is correct |
166 |
Correct |
47 ms |
14484 KB |
Output is correct |
167 |
Correct |
2 ms |
4944 KB |
Output is correct |
168 |
Correct |
3 ms |
4944 KB |
Output is correct |
169 |
Correct |
3 ms |
4944 KB |
Output is correct |
170 |
Correct |
701 ms |
8940 KB |
Output is correct |
171 |
Execution timed out |
4026 ms |
13688 KB |
Time limit exceeded |
172 |
Halted |
0 ms |
0 KB |
- |