#include <bits/stdc++.h>
#define pb push_back
#define pll pair <ll, ll>
#define MOMI using namespace std;
#define mp make_pair
#define pyshnapyshnakaa ios_base :: sync_with_stdio(0); cin.tie(0); cout.tie(0);
#pragma optimize("TKACHENKO-GORYACHENKO")
// #pragma GCC optimize("O3")
// #pragma GCC optimize("Ofast")
// #pragma GCC optimize("unroll-loops")
typedef int ll;
typedef long double ld;
using namespace std;
const ll inf = 2e9 + 500;
const ll maxn = 2e5 + 100;
const ll block = 100;
const ll block_sz = 2000;
ll n, m, k, t;
struct seg{
ll l;
ll r;
inline ll sz() const {
return r - l + 1;
}
ll i;
};
inline bool operator==(seg a, seg b) {
return a.i == b.i;
}
vector <seg> S;
struct R {
bool operator()(seg a, seg b) const {
if (a.r == b.r) {
return a.i < b.i;
}
return a.r < b.r;
}
};
struct L {
bool operator()(seg a, seg b) const {
if (a.l == b.l) {
return a.i < b.i;
}
return a.l < b.l;
}
};
vector <seg> lasts;
inline bool cmp(seg a, seg b) {
return (a.r - a.l) < (b.r - b.l);
}
inline bool cmpl(const seg& a, const seg& b) {
return a.l < b.l;
}
inline bool cmpr(const seg& a, const seg& b) {
return a.r < b.r;
}
inline bool cmpsz(const seg& a, const seg& b) {
return a.sz() < b.sz();
}
vector <seg> segs;
vector <seg> R[block];
vector <seg> L[block];
ll MNL[block];
ll MXL[block];
ll MNR[block];
ll MXR[block];
ll IL[maxn];
ll IR[maxn];
bool used[maxn];
inline void buildL(ll q) {
ll w;
if (q > block) {
exit(-1);
}
sort(L[q].begin(), L[q].end(), cmpsz);
MNL[q] = inf;
MXL[q] = -inf;
for (w = 0; w < L[q].size(); w++) {
MNL[q] = min(MNL[q], L[q][w].l);
MXL[q] = max(MXL[q], L[q][w].l);
}
}
inline void buildR(ll q) {
ll w;
if (q > block) {
exit(-1);
}
MNR[q] = inf;
MXR[q] = -inf;
sort(R[q].begin(), R[q].end(), cmpsz);
for (w = 0; w < R[q].size(); w++) {
MNR[q] = min(MNR[q], R[q][w].r);
MXR[q] = max(MXR[q], R[q][w].r);
}
}
inline void rebuild() {
ll q, w;
lasts.clear();
ll blocki = 0;
for (q = 0; q < block; q++) {
R[q].clear();
L[q].clear();
}
sort(segs.begin(), segs.end(), cmpl);
for (auto p : segs) {
if (used[p.i]) {
continue;
}
if (L[blocki].size() > block_sz) {
blocki++;
}
IL[p.i] = blocki;
L[blocki].pb(p);
}
sort(segs.begin(), segs.end(), cmpr);
for (auto p: segs) {
if (used[p.i]) {
continue;
}
if (R[blocki].size() > block_sz) {
blocki++;
}
IR[p.i] = blocki;
R[blocki].pb(p);
}
for (q = 0; q < block; q++) {
buildL(q);
}
for (q = 0; q < block; q++) {
buildR(q);
}
}
inline void add(seg a) {
lasts.pb(a);
S.pb(a);
segs.push_back(a);
IL[a.i] = IR[a.i] = -1;
}
inline void del(seg b) {
ll il = IL[b.i], ir = IR[b.i];
if (used[b.i]) {
return;
}
used[b.i] = 1;
if (il == -1) {
return;
}
L[il].erase(find(L[il].begin(), L[il].end(), b));
R[ir].erase(find(R[ir].begin(), R[ir].end(), b));
buildL(il);
buildR(ir);
}
inline ll slowL(ll i, ll x, ll l) {
ll q;
ll ans = 0;
for (q = 0; q < L[i].size(); q++) {
if (L[i][q].l >= l && L[i][q].sz() >= x) {
ans++;
}
}
return ans;
}
inline ll slowR(ll i, ll x, ll r) {
ll q;
ll ans = 0;
for (q = 0; q < R[i].size(); q++) {
if (R[i][q].r <= r && R[i][q].sz() >= x) {
ans++;
}
}
return ans;
}
inline ll fastL(ll i, ll x) {
if (L[i].empty()) {
return 0;
}
seg good;
good.l = 0; good.r = x - 1;
ll j = (lower_bound(L[i].begin(), L[i].end(), good, cmpsz) - L[i].begin());
return L[i].size() - j;
}
inline ll fastR(ll i, ll x) {
if (R[i].empty()) {
return 0;
}
seg good;
good.l = 0; good.r = x - 1;
ll j = (lower_bound(R[i].begin(), R[i].end(), good, cmpsz) - R[i].begin());
return R[i].size() - j;
}
inline ll getansL(ll x, ll l) {
ll q;
ll ans = 0;
for (q = 0; q < block; q++) {
if (MNL[q] == inf) {
continue;
}
if (MNL[q] >= l) {
ans += fastL(q, x);
continue;
}
if (MXL[q] < l) {
continue;
}
if (MNL[q] < l) {
ans += slowL(q, x, l);
}
}
for (q = 0; q < lasts.size(); q++) {
if (used[lasts[q].i]) {
continue;
}
if (lasts[q].l >= l && lasts[q].sz() >= x) {
ans++;
}
}
return ans;
}
inline ll getansR(ll x, ll r) {
ll q;
ll ans = 0;
ll cnt = 0;
for (q = 0; q < block; q++) {
if (MNR[q] == inf) {
continue;
}
// if (q > 1) {
// if (MXR[q - 1] > MNR[q]) {
// exit(-1);
// }
// }
if (MXR[q] <= r) {
ll dans = fastR(q, x);
ans += dans;
continue;
}
if (MNR[q] > r) {
continue;
}
/// MXR[q] > r && MNR[q] <= r,
ll dans = slowR(q, x, r);
ans += dans;
cnt++;
}
// if (cnt > 5) {
// exit(-1);
// }
for (q = 0; q < lasts.size(); q++) {
if (used[lasts[q].i]) {
continue;
}
if (lasts[q].r <= r && lasts[q].sz() >= x) {
ans++;
}
}
return ans;
}
inline ll answer(seg c, ll k) {
if (c.sz() < k) {
return 0;
}
ll q, w;
ll ans = 0;
ll lk = c.r - k + 2, rk = c.l + k - 2;
ll allans = getansR(k, inf);
ll dansl = getansL(k, lk);
ll dansr = getansR(k, rk);
ans = allans - dansr - dansl;
return ans;
}
signed main() {
ll q, w, e, a, b, c;
pyshnapyshnakaa;
cin >> n >> t;
// cout << block_sz * block << endl;
ll nxt = 0;
ll lastans = 0;
ll cnt3 = 0;
for (q = 0; q < n; q++) {
ll comm;
cin >> comm;
ll l, r;
seg x;
if (comm == 1) {
cin >> l >> r;
l ^= (lastans * t);
r ^= (lastans * t);
if (l > r) {
swap(l, r);
}
x.l = l; x.r = r;
x.i = S.size();
add(x);
}
if (comm == 2) {
cin >> a;
a--;
del(S[a]);
}
// if (cnt3 > 8e4 && n > 1e5) {
// exit(-1);
// }
if (comm == 3) {
cnt3++;
cin >> l >> r;
l ^= (lastans * t);
r ^= (lastans * t);
if (lasts.size() >= block_sz) {
rebuild();
}
if (l > r) {
swap(l, r);
}
x.l = l; x.r = r;
cin >> c;
lastans = answer(x, c);
cout << lastans << '\n';
}
}
return 0;
}
Compilation message
segments.cpp:7:0: warning: ignoring #pragma optimize [-Wunknown-pragmas]
#pragma optimize("TKACHENKO-GORYACHENKO")
segments.cpp: In function 'void buildL(ll)':
segments.cpp:100:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (w = 0; w < L[q].size(); w++) {
~~^~~~~~~~~~~~~
segments.cpp: In function 'void buildR(ll)':
segments.cpp:114:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (w = 0; w < R[q].size(); w++) {
~~^~~~~~~~~~~~~
segments.cpp: In function 'void rebuild()':
segments.cpp:121:8: warning: unused variable 'w' [-Wunused-variable]
ll q, w;
^
segments.cpp: In function 'll slowL(ll, ll, ll)':
segments.cpp:183:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (q = 0; q < L[i].size(); q++) {
~~^~~~~~~~~~~~~
segments.cpp: In function 'll slowR(ll, ll, ll)':
segments.cpp:194:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (q = 0; q < R[i].size(); q++) {
~~^~~~~~~~~~~~~
segments.cpp: In function 'll getansL(ll, ll)':
segments.cpp:241:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (q = 0; q < lasts.size(); q++) {
~~^~~~~~~~~~~~~~
segments.cpp: In function 'll getansR(ll, ll)':
segments.cpp:281:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (q = 0; q < lasts.size(); q++) {
~~^~~~~~~~~~~~~~
segments.cpp: In function 'll answer(seg, ll)':
segments.cpp:296:5: warning: unused variable 'q' [-Wunused-variable]
ll q, w;
^
segments.cpp:296:8: warning: unused variable 'w' [-Wunused-variable]
ll q, w;
^
segments.cpp: In function 'int main()':
segments.cpp:307:8: warning: unused variable 'w' [-Wunused-variable]
ll q, w, e, a, b, c;
^
segments.cpp:307:11: warning: unused variable 'e' [-Wunused-variable]
ll q, w, e, a, b, c;
^
segments.cpp:307:17: warning: unused variable 'b' [-Wunused-variable]
ll q, w, e, a, b, c;
^
segments.cpp:311:5: warning: unused variable 'nxt' [-Wunused-variable]
ll nxt = 0;
^~~
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
2 ms |
376 KB |
Output is correct |
2 |
Correct |
2 ms |
376 KB |
Output is correct |
3 |
Correct |
10 ms |
504 KB |
Output is correct |
4 |
Correct |
10 ms |
632 KB |
Output is correct |
5 |
Correct |
18 ms |
888 KB |
Output is correct |
6 |
Correct |
22 ms |
760 KB |
Output is correct |
7 |
Correct |
38 ms |
632 KB |
Output is correct |
8 |
Correct |
75 ms |
668 KB |
Output is correct |
9 |
Correct |
85 ms |
760 KB |
Output is correct |
10 |
Correct |
37 ms |
888 KB |
Output is correct |
11 |
Correct |
37 ms |
760 KB |
Output is correct |
12 |
Correct |
35 ms |
760 KB |
Output is correct |
13 |
Correct |
37 ms |
888 KB |
Output is correct |
14 |
Correct |
93 ms |
748 KB |
Output is correct |
15 |
Correct |
10 ms |
508 KB |
Output is correct |
16 |
Correct |
13 ms |
504 KB |
Output is correct |
17 |
Correct |
50 ms |
636 KB |
Output is correct |
18 |
Correct |
62 ms |
932 KB |
Output is correct |
19 |
Correct |
55 ms |
632 KB |
Output is correct |
20 |
Correct |
60 ms |
768 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1144 ms |
5264 KB |
Output is correct |
2 |
Correct |
1144 ms |
5440 KB |
Output is correct |
3 |
Correct |
1139 ms |
5456 KB |
Output is correct |
4 |
Correct |
1166 ms |
5708 KB |
Output is correct |
5 |
Correct |
239 ms |
8204 KB |
Output is correct |
6 |
Correct |
172 ms |
8212 KB |
Output is correct |
7 |
Correct |
1137 ms |
5436 KB |
Output is correct |
8 |
Correct |
1204 ms |
5404 KB |
Output is correct |
9 |
Correct |
1151 ms |
5620 KB |
Output is correct |
10 |
Correct |
1450 ms |
3768 KB |
Output is correct |
11 |
Correct |
1420 ms |
4056 KB |
Output is correct |
12 |
Correct |
804 ms |
6780 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
294 ms |
3412 KB |
Output is correct |
2 |
Correct |
259 ms |
2996 KB |
Output is correct |
3 |
Correct |
360 ms |
2992 KB |
Output is correct |
4 |
Correct |
258 ms |
2952 KB |
Output is correct |
5 |
Correct |
572 ms |
6172 KB |
Output is correct |
6 |
Correct |
723 ms |
5472 KB |
Output is correct |
7 |
Correct |
658 ms |
5768 KB |
Output is correct |
8 |
Correct |
191 ms |
7472 KB |
Output is correct |
9 |
Correct |
742 ms |
7524 KB |
Output is correct |
10 |
Correct |
2277 ms |
6180 KB |
Output is correct |
11 |
Correct |
1829 ms |
3020 KB |
Output is correct |
12 |
Correct |
2175 ms |
6056 KB |
Output is correct |
13 |
Correct |
2750 ms |
6132 KB |
Output is correct |
14 |
Correct |
3491 ms |
3944 KB |
Output is correct |
15 |
Correct |
3586 ms |
3692 KB |
Output is correct |
16 |
Correct |
3422 ms |
3232 KB |
Output is correct |
17 |
Correct |
880 ms |
5028 KB |
Output is correct |
18 |
Correct |
919 ms |
4944 KB |
Output is correct |
19 |
Correct |
886 ms |
4928 KB |
Output is correct |
20 |
Correct |
881 ms |
4908 KB |
Output is correct |
21 |
Correct |
2239 ms |
3340 KB |
Output is correct |
22 |
Correct |
3458 ms |
4760 KB |
Output is correct |
23 |
Correct |
2966 ms |
6180 KB |
Output is correct |
24 |
Correct |
3353 ms |
4852 KB |
Output is correct |
25 |
Correct |
298 ms |
3380 KB |
Output is correct |
26 |
Correct |
276 ms |
3320 KB |
Output is correct |
27 |
Correct |
289 ms |
3380 KB |
Output is correct |
28 |
Correct |
284 ms |
3260 KB |
Output is correct |
29 |
Correct |
2880 ms |
6212 KB |
Output is correct |
30 |
Correct |
2909 ms |
6392 KB |
Output is correct |
31 |
Correct |
673 ms |
7700 KB |
Output is correct |
32 |
Correct |
2243 ms |
6560 KB |
Output is correct |
33 |
Correct |
2498 ms |
6568 KB |
Output is correct |
34 |
Correct |
3434 ms |
4264 KB |
Output is correct |
35 |
Correct |
3027 ms |
5424 KB |
Output is correct |
36 |
Correct |
2330 ms |
6524 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
301 ms |
3232 KB |
Output is correct |
2 |
Correct |
259 ms |
3380 KB |
Output is correct |
3 |
Correct |
394 ms |
3384 KB |
Output is correct |
4 |
Correct |
290 ms |
3268 KB |
Output is correct |
5 |
Correct |
637 ms |
6924 KB |
Output is correct |
6 |
Correct |
1520 ms |
3292 KB |
Output is correct |
7 |
Correct |
514 ms |
7224 KB |
Output is correct |
8 |
Correct |
1493 ms |
3652 KB |
Output is correct |
9 |
Correct |
3695 ms |
4772 KB |
Output is correct |
10 |
Correct |
1987 ms |
6972 KB |
Output is correct |
11 |
Correct |
3486 ms |
3648 KB |
Output is correct |
12 |
Correct |
411 ms |
8348 KB |
Output is correct |
13 |
Correct |
2688 ms |
6724 KB |
Output is correct |
14 |
Correct |
3561 ms |
4252 KB |
Output is correct |
15 |
Correct |
824 ms |
7536 KB |
Output is correct |
16 |
Correct |
2478 ms |
6372 KB |
Output is correct |
17 |
Correct |
1132 ms |
4916 KB |
Output is correct |
18 |
Correct |
1129 ms |
5408 KB |
Output is correct |
19 |
Correct |
1138 ms |
5124 KB |
Output is correct |
20 |
Correct |
1125 ms |
5224 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
2 ms |
376 KB |
Output is correct |
2 |
Correct |
2 ms |
376 KB |
Output is correct |
3 |
Correct |
10 ms |
504 KB |
Output is correct |
4 |
Correct |
10 ms |
632 KB |
Output is correct |
5 |
Correct |
18 ms |
888 KB |
Output is correct |
6 |
Correct |
22 ms |
760 KB |
Output is correct |
7 |
Correct |
38 ms |
632 KB |
Output is correct |
8 |
Correct |
75 ms |
668 KB |
Output is correct |
9 |
Correct |
85 ms |
760 KB |
Output is correct |
10 |
Correct |
37 ms |
888 KB |
Output is correct |
11 |
Correct |
37 ms |
760 KB |
Output is correct |
12 |
Correct |
35 ms |
760 KB |
Output is correct |
13 |
Correct |
37 ms |
888 KB |
Output is correct |
14 |
Correct |
93 ms |
748 KB |
Output is correct |
15 |
Correct |
10 ms |
508 KB |
Output is correct |
16 |
Correct |
13 ms |
504 KB |
Output is correct |
17 |
Correct |
50 ms |
636 KB |
Output is correct |
18 |
Correct |
62 ms |
932 KB |
Output is correct |
19 |
Correct |
55 ms |
632 KB |
Output is correct |
20 |
Correct |
60 ms |
768 KB |
Output is correct |
21 |
Correct |
1144 ms |
5264 KB |
Output is correct |
22 |
Correct |
1144 ms |
5440 KB |
Output is correct |
23 |
Correct |
1139 ms |
5456 KB |
Output is correct |
24 |
Correct |
1166 ms |
5708 KB |
Output is correct |
25 |
Correct |
239 ms |
8204 KB |
Output is correct |
26 |
Correct |
172 ms |
8212 KB |
Output is correct |
27 |
Correct |
1137 ms |
5436 KB |
Output is correct |
28 |
Correct |
1204 ms |
5404 KB |
Output is correct |
29 |
Correct |
1151 ms |
5620 KB |
Output is correct |
30 |
Correct |
1450 ms |
3768 KB |
Output is correct |
31 |
Correct |
1420 ms |
4056 KB |
Output is correct |
32 |
Correct |
804 ms |
6780 KB |
Output is correct |
33 |
Correct |
301 ms |
3232 KB |
Output is correct |
34 |
Correct |
259 ms |
3380 KB |
Output is correct |
35 |
Correct |
394 ms |
3384 KB |
Output is correct |
36 |
Correct |
290 ms |
3268 KB |
Output is correct |
37 |
Correct |
637 ms |
6924 KB |
Output is correct |
38 |
Correct |
1520 ms |
3292 KB |
Output is correct |
39 |
Correct |
514 ms |
7224 KB |
Output is correct |
40 |
Correct |
1493 ms |
3652 KB |
Output is correct |
41 |
Correct |
3695 ms |
4772 KB |
Output is correct |
42 |
Correct |
1987 ms |
6972 KB |
Output is correct |
43 |
Correct |
3486 ms |
3648 KB |
Output is correct |
44 |
Correct |
411 ms |
8348 KB |
Output is correct |
45 |
Correct |
2688 ms |
6724 KB |
Output is correct |
46 |
Correct |
3561 ms |
4252 KB |
Output is correct |
47 |
Correct |
824 ms |
7536 KB |
Output is correct |
48 |
Correct |
2478 ms |
6372 KB |
Output is correct |
49 |
Correct |
1132 ms |
4916 KB |
Output is correct |
50 |
Correct |
1129 ms |
5408 KB |
Output is correct |
51 |
Correct |
1138 ms |
5124 KB |
Output is correct |
52 |
Correct |
1125 ms |
5224 KB |
Output is correct |
53 |
Correct |
281 ms |
3036 KB |
Output is correct |
54 |
Correct |
276 ms |
3044 KB |
Output is correct |
55 |
Correct |
255 ms |
3132 KB |
Output is correct |
56 |
Correct |
264 ms |
3128 KB |
Output is correct |
57 |
Correct |
1377 ms |
4136 KB |
Output is correct |
58 |
Correct |
1499 ms |
1784 KB |
Output is correct |
59 |
Correct |
949 ms |
4768 KB |
Output is correct |
60 |
Correct |
1435 ms |
1592 KB |
Output is correct |
61 |
Correct |
2725 ms |
5672 KB |
Output is correct |
62 |
Correct |
1070 ms |
6492 KB |
Output is correct |
63 |
Correct |
611 ms |
6896 KB |
Output is correct |
64 |
Correct |
994 ms |
6540 KB |
Output is correct |
65 |
Correct |
3523 ms |
2828 KB |
Output is correct |
66 |
Correct |
3386 ms |
2716 KB |
Output is correct |
67 |
Correct |
2402 ms |
5740 KB |
Output is correct |
68 |
Correct |
3092 ms |
4372 KB |
Output is correct |
69 |
Correct |
1365 ms |
4256 KB |
Output is correct |
70 |
Correct |
1138 ms |
4140 KB |
Output is correct |
71 |
Correct |
1167 ms |
4228 KB |
Output is correct |
72 |
Correct |
1135 ms |
4248 KB |
Output is correct |
73 |
Correct |
3633 ms |
3240 KB |
Output is correct |
74 |
Correct |
3220 ms |
4408 KB |
Output is correct |
75 |
Correct |
238 ms |
7060 KB |
Output is correct |
76 |
Correct |
561 ms |
7028 KB |
Output is correct |
77 |
Correct |
268 ms |
2356 KB |
Output is correct |
78 |
Correct |
272 ms |
2512 KB |
Output is correct |
79 |
Correct |
276 ms |
2360 KB |
Output is correct |
80 |
Correct |
266 ms |
2436 KB |
Output is correct |
81 |
Correct |
3314 ms |
4324 KB |
Output is correct |
82 |
Correct |
3735 ms |
3108 KB |
Output is correct |
83 |
Correct |
3215 ms |
2444 KB |
Output is correct |
84 |
Correct |
3312 ms |
4320 KB |
Output is correct |
85 |
Correct |
2353 ms |
5668 KB |
Output is correct |
86 |
Correct |
2214 ms |
5516 KB |
Output is correct |
87 |
Correct |
3483 ms |
3680 KB |
Output is correct |
88 |
Correct |
3195 ms |
2676 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
2 ms |
376 KB |
Output is correct |
2 |
Correct |
2 ms |
376 KB |
Output is correct |
3 |
Correct |
10 ms |
504 KB |
Output is correct |
4 |
Correct |
10 ms |
632 KB |
Output is correct |
5 |
Correct |
18 ms |
888 KB |
Output is correct |
6 |
Correct |
22 ms |
760 KB |
Output is correct |
7 |
Correct |
38 ms |
632 KB |
Output is correct |
8 |
Correct |
75 ms |
668 KB |
Output is correct |
9 |
Correct |
85 ms |
760 KB |
Output is correct |
10 |
Correct |
37 ms |
888 KB |
Output is correct |
11 |
Correct |
37 ms |
760 KB |
Output is correct |
12 |
Correct |
35 ms |
760 KB |
Output is correct |
13 |
Correct |
37 ms |
888 KB |
Output is correct |
14 |
Correct |
93 ms |
748 KB |
Output is correct |
15 |
Correct |
10 ms |
508 KB |
Output is correct |
16 |
Correct |
13 ms |
504 KB |
Output is correct |
17 |
Correct |
50 ms |
636 KB |
Output is correct |
18 |
Correct |
62 ms |
932 KB |
Output is correct |
19 |
Correct |
55 ms |
632 KB |
Output is correct |
20 |
Correct |
60 ms |
768 KB |
Output is correct |
21 |
Correct |
1144 ms |
5264 KB |
Output is correct |
22 |
Correct |
1144 ms |
5440 KB |
Output is correct |
23 |
Correct |
1139 ms |
5456 KB |
Output is correct |
24 |
Correct |
1166 ms |
5708 KB |
Output is correct |
25 |
Correct |
239 ms |
8204 KB |
Output is correct |
26 |
Correct |
172 ms |
8212 KB |
Output is correct |
27 |
Correct |
1137 ms |
5436 KB |
Output is correct |
28 |
Correct |
1204 ms |
5404 KB |
Output is correct |
29 |
Correct |
1151 ms |
5620 KB |
Output is correct |
30 |
Correct |
1450 ms |
3768 KB |
Output is correct |
31 |
Correct |
1420 ms |
4056 KB |
Output is correct |
32 |
Correct |
804 ms |
6780 KB |
Output is correct |
33 |
Correct |
294 ms |
3412 KB |
Output is correct |
34 |
Correct |
259 ms |
2996 KB |
Output is correct |
35 |
Correct |
360 ms |
2992 KB |
Output is correct |
36 |
Correct |
258 ms |
2952 KB |
Output is correct |
37 |
Correct |
572 ms |
6172 KB |
Output is correct |
38 |
Correct |
723 ms |
5472 KB |
Output is correct |
39 |
Correct |
658 ms |
5768 KB |
Output is correct |
40 |
Correct |
191 ms |
7472 KB |
Output is correct |
41 |
Correct |
742 ms |
7524 KB |
Output is correct |
42 |
Correct |
2277 ms |
6180 KB |
Output is correct |
43 |
Correct |
1829 ms |
3020 KB |
Output is correct |
44 |
Correct |
2175 ms |
6056 KB |
Output is correct |
45 |
Correct |
2750 ms |
6132 KB |
Output is correct |
46 |
Correct |
3491 ms |
3944 KB |
Output is correct |
47 |
Correct |
3586 ms |
3692 KB |
Output is correct |
48 |
Correct |
3422 ms |
3232 KB |
Output is correct |
49 |
Correct |
880 ms |
5028 KB |
Output is correct |
50 |
Correct |
919 ms |
4944 KB |
Output is correct |
51 |
Correct |
886 ms |
4928 KB |
Output is correct |
52 |
Correct |
881 ms |
4908 KB |
Output is correct |
53 |
Correct |
2239 ms |
3340 KB |
Output is correct |
54 |
Correct |
3458 ms |
4760 KB |
Output is correct |
55 |
Correct |
2966 ms |
6180 KB |
Output is correct |
56 |
Correct |
3353 ms |
4852 KB |
Output is correct |
57 |
Correct |
298 ms |
3380 KB |
Output is correct |
58 |
Correct |
276 ms |
3320 KB |
Output is correct |
59 |
Correct |
289 ms |
3380 KB |
Output is correct |
60 |
Correct |
284 ms |
3260 KB |
Output is correct |
61 |
Correct |
2880 ms |
6212 KB |
Output is correct |
62 |
Correct |
2909 ms |
6392 KB |
Output is correct |
63 |
Correct |
673 ms |
7700 KB |
Output is correct |
64 |
Correct |
2243 ms |
6560 KB |
Output is correct |
65 |
Correct |
2498 ms |
6568 KB |
Output is correct |
66 |
Correct |
3434 ms |
4264 KB |
Output is correct |
67 |
Correct |
3027 ms |
5424 KB |
Output is correct |
68 |
Correct |
2330 ms |
6524 KB |
Output is correct |
69 |
Correct |
301 ms |
3232 KB |
Output is correct |
70 |
Correct |
259 ms |
3380 KB |
Output is correct |
71 |
Correct |
394 ms |
3384 KB |
Output is correct |
72 |
Correct |
290 ms |
3268 KB |
Output is correct |
73 |
Correct |
637 ms |
6924 KB |
Output is correct |
74 |
Correct |
1520 ms |
3292 KB |
Output is correct |
75 |
Correct |
514 ms |
7224 KB |
Output is correct |
76 |
Correct |
1493 ms |
3652 KB |
Output is correct |
77 |
Correct |
3695 ms |
4772 KB |
Output is correct |
78 |
Correct |
1987 ms |
6972 KB |
Output is correct |
79 |
Correct |
3486 ms |
3648 KB |
Output is correct |
80 |
Correct |
411 ms |
8348 KB |
Output is correct |
81 |
Correct |
2688 ms |
6724 KB |
Output is correct |
82 |
Correct |
3561 ms |
4252 KB |
Output is correct |
83 |
Correct |
824 ms |
7536 KB |
Output is correct |
84 |
Correct |
2478 ms |
6372 KB |
Output is correct |
85 |
Correct |
1132 ms |
4916 KB |
Output is correct |
86 |
Correct |
1129 ms |
5408 KB |
Output is correct |
87 |
Correct |
1138 ms |
5124 KB |
Output is correct |
88 |
Correct |
1125 ms |
5224 KB |
Output is correct |
89 |
Correct |
281 ms |
3036 KB |
Output is correct |
90 |
Correct |
276 ms |
3044 KB |
Output is correct |
91 |
Correct |
255 ms |
3132 KB |
Output is correct |
92 |
Correct |
264 ms |
3128 KB |
Output is correct |
93 |
Correct |
1377 ms |
4136 KB |
Output is correct |
94 |
Correct |
1499 ms |
1784 KB |
Output is correct |
95 |
Correct |
949 ms |
4768 KB |
Output is correct |
96 |
Correct |
1435 ms |
1592 KB |
Output is correct |
97 |
Correct |
2725 ms |
5672 KB |
Output is correct |
98 |
Correct |
1070 ms |
6492 KB |
Output is correct |
99 |
Correct |
611 ms |
6896 KB |
Output is correct |
100 |
Correct |
994 ms |
6540 KB |
Output is correct |
101 |
Correct |
3523 ms |
2828 KB |
Output is correct |
102 |
Correct |
3386 ms |
2716 KB |
Output is correct |
103 |
Correct |
2402 ms |
5740 KB |
Output is correct |
104 |
Correct |
3092 ms |
4372 KB |
Output is correct |
105 |
Correct |
1365 ms |
4256 KB |
Output is correct |
106 |
Correct |
1138 ms |
4140 KB |
Output is correct |
107 |
Correct |
1167 ms |
4228 KB |
Output is correct |
108 |
Correct |
1135 ms |
4248 KB |
Output is correct |
109 |
Correct |
3633 ms |
3240 KB |
Output is correct |
110 |
Correct |
3220 ms |
4408 KB |
Output is correct |
111 |
Correct |
238 ms |
7060 KB |
Output is correct |
112 |
Correct |
561 ms |
7028 KB |
Output is correct |
113 |
Correct |
268 ms |
2356 KB |
Output is correct |
114 |
Correct |
272 ms |
2512 KB |
Output is correct |
115 |
Correct |
276 ms |
2360 KB |
Output is correct |
116 |
Correct |
266 ms |
2436 KB |
Output is correct |
117 |
Correct |
3314 ms |
4324 KB |
Output is correct |
118 |
Correct |
3735 ms |
3108 KB |
Output is correct |
119 |
Correct |
3215 ms |
2444 KB |
Output is correct |
120 |
Correct |
3312 ms |
4320 KB |
Output is correct |
121 |
Correct |
2353 ms |
5668 KB |
Output is correct |
122 |
Correct |
2214 ms |
5516 KB |
Output is correct |
123 |
Correct |
3483 ms |
3680 KB |
Output is correct |
124 |
Correct |
3195 ms |
2676 KB |
Output is correct |
125 |
Correct |
709 ms |
3924 KB |
Output is correct |
126 |
Correct |
704 ms |
3752 KB |
Output is correct |
127 |
Correct |
931 ms |
3956 KB |
Output is correct |
128 |
Correct |
722 ms |
3984 KB |
Output is correct |
129 |
Correct |
681 ms |
3936 KB |
Output is correct |
130 |
Correct |
821 ms |
4040 KB |
Output is correct |
131 |
Correct |
3257 ms |
2852 KB |
Output is correct |
132 |
Correct |
3062 ms |
7132 KB |
Output is correct |
133 |
Runtime error |
111 ms |
17044 KB |
Execution killed with signal 11 (could be triggered by violating memory limits) |
134 |
Halted |
0 ms |
0 KB |
- |