/**
____ ____ ____ ____ ____ ____
||l |||e |||i |||n |||a |||d ||
||__|||__|||__|||__|||__|||__||
|/__\|/__\|/__\|/__\|/__\|/__\|
**/
#include<bits/stdc++.h>
#define endl '\n'
using namespace std;
typedef long long ll;
void speed()
{
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cout.tie(NULL);
}
const ll maxn = 3e5 + 10;
ll n, q;
ll d[maxn], b[maxn];
void input()
{
cin >> n >> q;
for (ll i = 1; i <= n; i ++)
{
cin >> d[i];
b[i] = d[i] - d[i - 1];
}
}
ll query(ll l, ll r)
{
if (l == r)
return 1;
ll cnt = 1, mx = 0;
for (ll i = l + 2; i <= r; i ++)
{
if (b[i] == b[i -1])
cnt ++;
else
{
if (cnt > mx)
mx = cnt;
cnt = 1;
}
}
if (cnt > mx)
mx = cnt;
return mx + 1;
}
const ll inf = 2e18;
struct line
{
ll k, m;
line(ll _k = 0, ll _m = 0)
{
k = _k;
m = _m;
}
ll math(ll x)
{
return k * x + m;
}
void add_line(line cur)
{
k += cur.k;
m += cur.m;
}
void set_line(line cur)
{
k = cur.k;
m = cur.m;
}
};
line set_lazy[4 * maxn], add_lazy[4 * maxn];
ll set_tag[4 * maxn], add_tag[4 * maxn];
void push_lazy(ll root, ll left, ll right)
{
ll mid = (left + right) / 2;
if (set_tag[root] == 1)
{
///li_chao[root].set_line(set_lazy[root]);
if (left != right)
{
set_tag[root * 2] = 1;
set_tag[root * 2 + 1] = 1;
add_tag[root * 2] = 0;
add_tag[root * 2 + 1] = 0;
set_lazy[root * 2] = set_lazy[root];
set_lazy[root * 2 + 1] = set_lazy[root];
add_lazy[root * 2] = line(0, 0);
add_lazy[root * 2 + 1] = line(0, 0);
}
else
{
d[left] = set_lazy[root].math(left);
}
set_tag[root] = 0;
set_lazy[root] = line(0, 0);
}
if (add_tag[root] == 1)
{
if (left != right)
{
add_tag[root * 2] = 1;
add_tag[root * 2 + 1] = 1;
add_lazy[root * 2].add_line(add_lazy[root]);
add_lazy[root * 2 + 1].add_line(add_lazy[root]);
}
else
{
d[left] += add_lazy[root].math(left);
}
add_tag[root] = 0;
add_lazy[root] = line(0, 0);
}
}
void set_line(ll root, ll left, ll right, ll qleft, ll qright, line cur)
{
push_lazy(root, left, right);
if (left > qright || right < qleft)
return;
if (left >= qleft && right <= qright)
{
set_tag[root] = 1;
set_lazy[root] = cur;
push_lazy(root, left, right);
return;
}
ll mid = (left + right) / 2;
set_line(root * 2, left, mid, qleft, qright, cur);
set_line(root * 2 + 1, mid + 1, right, qleft, qright, cur);
}
void add_line(ll root, ll left, ll right, ll qleft, ll qright, line cur)
{
push_lazy(root, left, right);
if (left > qright || right < qleft)
return;
if (left >= qleft && right <= qright)
{
add_tag[root] = 1;
add_lazy[root] = cur;
push_lazy(root, left, right);
return;
}
ll mid = (left + right) / 2;
add_line(root * 2, left, mid, qleft, qright, cur);
add_line(root * 2 + 1, mid + 1, right, qleft, qright, cur);
}
ll query(ll root, ll left, ll right, ll pos)
{
push_lazy(root, left, right);
if (left == right)
return d[left];
ll mid = (left + right) / 2;
if (pos <= mid)
return query(root * 2, left, mid, pos);
return query(root * 2 + 1, mid + 1, right, pos);
}
/**void add_line_concious(ll root, ll left, ll right, line cur)
{
push_lazy(root, left, right);
ll mid = (left + right) / 2;
if (li_chao[root].math(mid) < cur.math(mid))
swap(li_chao[root], cur);
if (left == right)
return;
if ()
}*/
struct node
{
ll pref, suff, lon, len;
ll fs, ls;
node(ll _pref = 0, ll _suff = 0, ll _lon = 0, ll _fs = -inf, ll _ls = inf, ll _len = 0)
{
len = _len;
pref = _pref;
suff = _suff;
lon = _lon;
fs = _fs;
ls = _ls;
}
};
node merge_nodes(node lf, node rf)
{
if (lf.ls == inf)
return rf;
if (rf.fs == -inf)
return lf;
node mf;
mf.fs = lf.fs;
mf.ls = rf.ls;
mf.pref = lf.pref;
if (lf.pref == lf.len && lf.ls == rf.fs)
mf.pref += rf.pref;
mf.suff = rf.suff;
if (rf.suff == rf.len && rf.fs == lf.ls)
mf.suff += lf.suff;
mf.lon = max(lf.lon, rf.lon);
if (lf.ls == rf.fs)
mf.lon = max(mf.lon, lf.suff + rf.pref);
mf.len = lf.len + rf.len;
return mf;
}
node tree[4 * maxn];
pair < ll, ll > lazy[4 * maxn];
pair < ll, ll > tag[4 * maxn];
void make_lazy(ll root, ll left, ll right)
{
if (tag[root].first)
{
ll len = right - left + 1;
tree[root] = node(len, len, len, lazy[root].first, lazy[root].first, len);
if (left != right)
{
tag[root * 2].first = 1;
tag[root * 2 + 1].first = 1;
tag[root * 2].second = 0;
tag[root * 2 + 1].second = 0;
lazy[root * 2].second = 0;
lazy[root * 2 + 1].second = 0;
lazy[root * 2].first = lazy[root].first;
lazy[root * 2 + 1].first = lazy[root].first;
}
lazy[root].first = 0;
tag[root].first = 0;
}
if (tag[root].second)
{
tree[root].fs += lazy[root].second;
tree[root].ls += lazy[root].second;
if (left != right)
{
tag[root * 2].second = 1;
tag[root * 2 + 1].second = 1;
lazy[root * 2].second += lazy[root].second;
lazy[root * 2 + 1].second += lazy[root].second;
}
tag[root].second = 0;
lazy[root].second = 0;
}
}
void range_update_set(ll root, ll left, ll right, ll qleft, ll qright, ll val)
{
make_lazy(root, left, right);
if (left > qright || right < qleft)
return;
if (left >= qleft && right <= qright)
{
lazy[root].first = val;
tag[root].first = 1;
make_lazy(root, left, right);
return;
}
ll mid = (left + right) / 2;
range_update_set(root * 2, left, mid, qleft, qright, val);
range_update_set(root * 2 + 1, mid + 1, right, qleft, qright, val);
tree[root] = merge_nodes(tree[root * 2], tree[root * 2 + 1]);
}
void range_update_add(ll root, ll left, ll right, ll qleft, ll qright, ll val)
{
make_lazy(root, left, right);
if (left > qright || right < qleft)
return;
if (left >= qleft && right <= qright)
{
lazy[root].second =val;
tag[root].second = 1;
make_lazy(root, left, right);
return;
}
ll mid = (left + right) / 2;
range_update_add(root * 2, left, mid, qleft, qright, val);
range_update_add(root * 2 + 1, mid + 1, right, qleft, qright, val);
tree[root] = merge_nodes(tree[root * 2], tree[root * 2 + 1]);
}
node query_range(ll root, ll left, ll right, ll qleft, ll qright)
{
make_lazy(root, left, right);
if (left > qright || right < qleft)
return node();
if (left >= qleft && right <= qright)
{
return tree[root];
}
ll mid = (left + right) / 2;
return merge_nodes(query_range(root * 2, left, mid, qleft, qright),
query_range(root * 2 + 1, mid + 1, right, qleft, qright));
}
void build_tree(ll root, ll left, ll right)
{
if (left == right)
{
tree[root] = node(1, 1, 1, b[left], b[left], 1);
return;
}
ll mid = (left + right) / 2;
build_tree(root * 2, left, mid);
build_tree(root * 2 + 1, mid + 1, right);
tree[root] = merge_nodes(tree[root * 2], tree[root * 2 + 1]);
}
void simulate()
{
build_tree(1, 1, n);
for (ll i = 1; i <= q; i ++)
{
ll type, l, r;
ll s, c;
cin >> type >> l >> r;
if (type == 3)
{
node cur = query_range(1, 1, n, l + 1, r);
cout << cur.lon + 1 << endl;
///cout << query(l, r) << endl;
}
else if (type == 1)
{
cin >> s >> c;
add_line(1, 1, n, l, r, line(c, - l * c + s));
/*for (ll j = l; j <= r; j ++)
{
d[j] += s + (ll)(j - l) * c;
}*/
range_update_add(1, 1, n, l + 1, r, c);
range_update_add(1, 1, n, l, l, s);
//b[l] += s;
//for (ll j = l + 1; j <= r; j ++)
// b[j] += c;
if (r + 1 <= n)
range_update_set(1, 1, n, r + 1, r + 1, query(1, 1, n, r + 1) - query(1, 1, n, r));
// b[r + 1] = query(1, 1, n, r + 1) - query(1, 1, n, r); ///d[r + 1] - d[r];
}
else
{
cin >> s >> c;
set_line(1, 1, n, l, r, line(c, - l * c + s));
/**for (ll j = l; j <= r; j ++)
{
d[j] = s + (ll)(j - l) * c;
}*/
range_update_set(1, 1, n, l + 1, r, c);
//for (ll j = l + 1; j <= r; j ++)
// b[j] = c;
range_update_set(1, 1, n, l, l, query(1, 1, n, l) - query(1, 1, n, l - 1));
///b[l] = query(1, 1, n, l) - query(1, 1, n, l - 1); ///d[l] - d[l - 1];
if (r + 1 <= n)
range_update_set(1, 1, n, r + 1, r + 1, query(1, 1, n, r + 1) - query(1, 1, n, r));
//b[r + 1] = query(1, 1, n, r + 1) - query(1, 1, n, r); ///d[r + 1] - d[r];
}
/**for (ll j = 2; j <= n; j ++)
{
if (b[j] != query_range(1, 1, n, j, j).fs)
{
while(true);
}
}*/
/**for (ll j = 1; j <= n; j ++)
{
b[j] = d[j] - d[j - 1];
}*/
/**for (ll j = 1; j <= n; j ++)
cout << d[j] << " ";
cout << endl;*/
}
}
void solve()
{
input();
simulate();
}
int main()
{
speed();
solve();
return 0;
}
Compilation message
Progression.cpp: In function 'void push_lazy(ll, ll, ll)':
Progression.cpp:93:8: warning: unused variable 'mid' [-Wunused-variable]
93 | ll mid = (left + right) / 2;
| ^~~
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
380 ms |
119040 KB |
Output is correct |
2 |
Correct |
146 ms |
103156 KB |
Output is correct |
3 |
Correct |
140 ms |
103284 KB |
Output is correct |
4 |
Correct |
138 ms |
103252 KB |
Output is correct |
5 |
Correct |
141 ms |
103508 KB |
Output is correct |
6 |
Correct |
139 ms |
103248 KB |
Output is correct |
7 |
Correct |
139 ms |
103284 KB |
Output is correct |
8 |
Correct |
18 ms |
102936 KB |
Output is correct |
9 |
Correct |
20 ms |
103004 KB |
Output is correct |
10 |
Correct |
18 ms |
103056 KB |
Output is correct |
11 |
Correct |
354 ms |
119056 KB |
Output is correct |
12 |
Correct |
349 ms |
118868 KB |
Output is correct |
13 |
Correct |
355 ms |
119176 KB |
Output is correct |
14 |
Correct |
354 ms |
119124 KB |
Output is correct |
15 |
Correct |
354 ms |
119168 KB |
Output is correct |
16 |
Correct |
356 ms |
118816 KB |
Output is correct |
17 |
Correct |
350 ms |
118984 KB |
Output is correct |
18 |
Correct |
354 ms |
118864 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
21 ms |
103000 KB |
Output is correct |
2 |
Correct |
19 ms |
103004 KB |
Output is correct |
3 |
Correct |
19 ms |
102988 KB |
Output is correct |
4 |
Correct |
20 ms |
103000 KB |
Output is correct |
5 |
Correct |
18 ms |
103004 KB |
Output is correct |
6 |
Correct |
18 ms |
103008 KB |
Output is correct |
7 |
Correct |
20 ms |
103004 KB |
Output is correct |
8 |
Correct |
22 ms |
103004 KB |
Output is correct |
9 |
Correct |
20 ms |
103004 KB |
Output is correct |
10 |
Correct |
20 ms |
103004 KB |
Output is correct |
11 |
Correct |
20 ms |
103256 KB |
Output is correct |
12 |
Correct |
21 ms |
103000 KB |
Output is correct |
13 |
Correct |
20 ms |
103004 KB |
Output is correct |
14 |
Correct |
19 ms |
103004 KB |
Output is correct |
15 |
Correct |
21 ms |
103004 KB |
Output is correct |
16 |
Correct |
23 ms |
103004 KB |
Output is correct |
17 |
Correct |
21 ms |
103012 KB |
Output is correct |
18 |
Correct |
20 ms |
102988 KB |
Output is correct |
19 |
Correct |
19 ms |
102892 KB |
Output is correct |
20 |
Correct |
20 ms |
103000 KB |
Output is correct |
21 |
Correct |
20 ms |
103004 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
299 ms |
102852 KB |
Output is correct |
2 |
Correct |
105 ms |
101460 KB |
Output is correct |
3 |
Correct |
98 ms |
101556 KB |
Output is correct |
4 |
Correct |
99 ms |
101584 KB |
Output is correct |
5 |
Correct |
100 ms |
101576 KB |
Output is correct |
6 |
Correct |
99 ms |
101612 KB |
Output is correct |
7 |
Correct |
105 ms |
101420 KB |
Output is correct |
8 |
Correct |
18 ms |
100952 KB |
Output is correct |
9 |
Correct |
19 ms |
100940 KB |
Output is correct |
10 |
Correct |
19 ms |
100956 KB |
Output is correct |
11 |
Correct |
319 ms |
102540 KB |
Output is correct |
12 |
Correct |
302 ms |
102992 KB |
Output is correct |
13 |
Correct |
310 ms |
102740 KB |
Output is correct |
14 |
Correct |
341 ms |
102712 KB |
Output is correct |
15 |
Correct |
293 ms |
102740 KB |
Output is correct |
16 |
Correct |
346 ms |
103528 KB |
Output is correct |
17 |
Correct |
345 ms |
103248 KB |
Output is correct |
18 |
Correct |
351 ms |
103232 KB |
Output is correct |
19 |
Correct |
296 ms |
102488 KB |
Output is correct |
20 |
Correct |
307 ms |
102664 KB |
Output is correct |
21 |
Correct |
291 ms |
102536 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
904 ms |
140640 KB |
Output is correct |
2 |
Correct |
179 ms |
103236 KB |
Output is correct |
3 |
Correct |
176 ms |
103256 KB |
Output is correct |
4 |
Correct |
178 ms |
103252 KB |
Output is correct |
5 |
Correct |
190 ms |
103384 KB |
Output is correct |
6 |
Correct |
182 ms |
103104 KB |
Output is correct |
7 |
Correct |
181 ms |
103068 KB |
Output is correct |
8 |
Correct |
20 ms |
102884 KB |
Output is correct |
9 |
Correct |
19 ms |
103004 KB |
Output is correct |
10 |
Correct |
19 ms |
103004 KB |
Output is correct |
11 |
Correct |
960 ms |
140824 KB |
Output is correct |
12 |
Correct |
892 ms |
140628 KB |
Output is correct |
13 |
Correct |
948 ms |
140892 KB |
Output is correct |
14 |
Correct |
988 ms |
140628 KB |
Output is correct |
15 |
Correct |
946 ms |
140484 KB |
Output is correct |
16 |
Correct |
1006 ms |
140508 KB |
Output is correct |
17 |
Correct |
1022 ms |
140804 KB |
Output is correct |
18 |
Correct |
936 ms |
140656 KB |
Output is correct |
19 |
Correct |
872 ms |
140528 KB |
Output is correct |
20 |
Correct |
872 ms |
140368 KB |
Output is correct |
21 |
Correct |
892 ms |
140372 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
299 ms |
102852 KB |
Output is correct |
2 |
Correct |
105 ms |
101460 KB |
Output is correct |
3 |
Correct |
98 ms |
101556 KB |
Output is correct |
4 |
Correct |
99 ms |
101584 KB |
Output is correct |
5 |
Correct |
100 ms |
101576 KB |
Output is correct |
6 |
Correct |
99 ms |
101612 KB |
Output is correct |
7 |
Correct |
105 ms |
101420 KB |
Output is correct |
8 |
Correct |
18 ms |
100952 KB |
Output is correct |
9 |
Correct |
19 ms |
100940 KB |
Output is correct |
10 |
Correct |
19 ms |
100956 KB |
Output is correct |
11 |
Correct |
319 ms |
102540 KB |
Output is correct |
12 |
Correct |
302 ms |
102992 KB |
Output is correct |
13 |
Correct |
310 ms |
102740 KB |
Output is correct |
14 |
Correct |
341 ms |
102712 KB |
Output is correct |
15 |
Correct |
293 ms |
102740 KB |
Output is correct |
16 |
Correct |
346 ms |
103528 KB |
Output is correct |
17 |
Correct |
345 ms |
103248 KB |
Output is correct |
18 |
Correct |
351 ms |
103232 KB |
Output is correct |
19 |
Correct |
296 ms |
102488 KB |
Output is correct |
20 |
Correct |
307 ms |
102664 KB |
Output is correct |
21 |
Correct |
291 ms |
102536 KB |
Output is correct |
22 |
Correct |
1212 ms |
144724 KB |
Output is correct |
23 |
Correct |
181 ms |
103252 KB |
Output is correct |
24 |
Correct |
177 ms |
106064 KB |
Output is correct |
25 |
Correct |
178 ms |
106216 KB |
Output is correct |
26 |
Correct |
196 ms |
106320 KB |
Output is correct |
27 |
Correct |
188 ms |
106196 KB |
Output is correct |
28 |
Correct |
179 ms |
106240 KB |
Output is correct |
29 |
Correct |
20 ms |
102992 KB |
Output is correct |
30 |
Correct |
19 ms |
103004 KB |
Output is correct |
31 |
Correct |
19 ms |
103000 KB |
Output is correct |
32 |
Correct |
1253 ms |
151816 KB |
Output is correct |
33 |
Correct |
1212 ms |
154340 KB |
Output is correct |
34 |
Correct |
1222 ms |
150720 KB |
Output is correct |
35 |
Correct |
1190 ms |
150864 KB |
Output is correct |
36 |
Correct |
937 ms |
150772 KB |
Output is correct |
37 |
Correct |
939 ms |
151288 KB |
Output is correct |
38 |
Correct |
873 ms |
151448 KB |
Output is correct |
39 |
Correct |
1225 ms |
154460 KB |
Output is correct |
40 |
Correct |
1242 ms |
154136 KB |
Output is correct |
41 |
Correct |
1202 ms |
153768 KB |
Output is correct |
42 |
Correct |
1253 ms |
154260 KB |
Output is correct |
43 |
Correct |
1186 ms |
154180 KB |
Output is correct |
44 |
Correct |
1202 ms |
154332 KB |
Output is correct |
45 |
Correct |
1201 ms |
153672 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
380 ms |
119040 KB |
Output is correct |
2 |
Correct |
146 ms |
103156 KB |
Output is correct |
3 |
Correct |
140 ms |
103284 KB |
Output is correct |
4 |
Correct |
138 ms |
103252 KB |
Output is correct |
5 |
Correct |
141 ms |
103508 KB |
Output is correct |
6 |
Correct |
139 ms |
103248 KB |
Output is correct |
7 |
Correct |
139 ms |
103284 KB |
Output is correct |
8 |
Correct |
18 ms |
102936 KB |
Output is correct |
9 |
Correct |
20 ms |
103004 KB |
Output is correct |
10 |
Correct |
18 ms |
103056 KB |
Output is correct |
11 |
Correct |
354 ms |
119056 KB |
Output is correct |
12 |
Correct |
349 ms |
118868 KB |
Output is correct |
13 |
Correct |
355 ms |
119176 KB |
Output is correct |
14 |
Correct |
354 ms |
119124 KB |
Output is correct |
15 |
Correct |
354 ms |
119168 KB |
Output is correct |
16 |
Correct |
356 ms |
118816 KB |
Output is correct |
17 |
Correct |
350 ms |
118984 KB |
Output is correct |
18 |
Correct |
354 ms |
118864 KB |
Output is correct |
19 |
Correct |
21 ms |
103000 KB |
Output is correct |
20 |
Correct |
19 ms |
103004 KB |
Output is correct |
21 |
Correct |
19 ms |
102988 KB |
Output is correct |
22 |
Correct |
20 ms |
103000 KB |
Output is correct |
23 |
Correct |
18 ms |
103004 KB |
Output is correct |
24 |
Correct |
18 ms |
103008 KB |
Output is correct |
25 |
Correct |
20 ms |
103004 KB |
Output is correct |
26 |
Correct |
22 ms |
103004 KB |
Output is correct |
27 |
Correct |
20 ms |
103004 KB |
Output is correct |
28 |
Correct |
20 ms |
103004 KB |
Output is correct |
29 |
Correct |
20 ms |
103256 KB |
Output is correct |
30 |
Correct |
21 ms |
103000 KB |
Output is correct |
31 |
Correct |
20 ms |
103004 KB |
Output is correct |
32 |
Correct |
19 ms |
103004 KB |
Output is correct |
33 |
Correct |
21 ms |
103004 KB |
Output is correct |
34 |
Correct |
23 ms |
103004 KB |
Output is correct |
35 |
Correct |
21 ms |
103012 KB |
Output is correct |
36 |
Correct |
20 ms |
102988 KB |
Output is correct |
37 |
Correct |
19 ms |
102892 KB |
Output is correct |
38 |
Correct |
20 ms |
103000 KB |
Output is correct |
39 |
Correct |
20 ms |
103004 KB |
Output is correct |
40 |
Correct |
299 ms |
102852 KB |
Output is correct |
41 |
Correct |
105 ms |
101460 KB |
Output is correct |
42 |
Correct |
98 ms |
101556 KB |
Output is correct |
43 |
Correct |
99 ms |
101584 KB |
Output is correct |
44 |
Correct |
100 ms |
101576 KB |
Output is correct |
45 |
Correct |
99 ms |
101612 KB |
Output is correct |
46 |
Correct |
105 ms |
101420 KB |
Output is correct |
47 |
Correct |
18 ms |
100952 KB |
Output is correct |
48 |
Correct |
19 ms |
100940 KB |
Output is correct |
49 |
Correct |
19 ms |
100956 KB |
Output is correct |
50 |
Correct |
319 ms |
102540 KB |
Output is correct |
51 |
Correct |
302 ms |
102992 KB |
Output is correct |
52 |
Correct |
310 ms |
102740 KB |
Output is correct |
53 |
Correct |
341 ms |
102712 KB |
Output is correct |
54 |
Correct |
293 ms |
102740 KB |
Output is correct |
55 |
Correct |
346 ms |
103528 KB |
Output is correct |
56 |
Correct |
345 ms |
103248 KB |
Output is correct |
57 |
Correct |
351 ms |
103232 KB |
Output is correct |
58 |
Correct |
296 ms |
102488 KB |
Output is correct |
59 |
Correct |
307 ms |
102664 KB |
Output is correct |
60 |
Correct |
291 ms |
102536 KB |
Output is correct |
61 |
Correct |
904 ms |
140640 KB |
Output is correct |
62 |
Correct |
179 ms |
103236 KB |
Output is correct |
63 |
Correct |
176 ms |
103256 KB |
Output is correct |
64 |
Correct |
178 ms |
103252 KB |
Output is correct |
65 |
Correct |
190 ms |
103384 KB |
Output is correct |
66 |
Correct |
182 ms |
103104 KB |
Output is correct |
67 |
Correct |
181 ms |
103068 KB |
Output is correct |
68 |
Correct |
20 ms |
102884 KB |
Output is correct |
69 |
Correct |
19 ms |
103004 KB |
Output is correct |
70 |
Correct |
19 ms |
103004 KB |
Output is correct |
71 |
Correct |
960 ms |
140824 KB |
Output is correct |
72 |
Correct |
892 ms |
140628 KB |
Output is correct |
73 |
Correct |
948 ms |
140892 KB |
Output is correct |
74 |
Correct |
988 ms |
140628 KB |
Output is correct |
75 |
Correct |
946 ms |
140484 KB |
Output is correct |
76 |
Correct |
1006 ms |
140508 KB |
Output is correct |
77 |
Correct |
1022 ms |
140804 KB |
Output is correct |
78 |
Correct |
936 ms |
140656 KB |
Output is correct |
79 |
Correct |
872 ms |
140528 KB |
Output is correct |
80 |
Correct |
872 ms |
140368 KB |
Output is correct |
81 |
Correct |
892 ms |
140372 KB |
Output is correct |
82 |
Correct |
1212 ms |
144724 KB |
Output is correct |
83 |
Correct |
181 ms |
103252 KB |
Output is correct |
84 |
Correct |
177 ms |
106064 KB |
Output is correct |
85 |
Correct |
178 ms |
106216 KB |
Output is correct |
86 |
Correct |
196 ms |
106320 KB |
Output is correct |
87 |
Correct |
188 ms |
106196 KB |
Output is correct |
88 |
Correct |
179 ms |
106240 KB |
Output is correct |
89 |
Correct |
20 ms |
102992 KB |
Output is correct |
90 |
Correct |
19 ms |
103004 KB |
Output is correct |
91 |
Correct |
19 ms |
103000 KB |
Output is correct |
92 |
Correct |
1253 ms |
151816 KB |
Output is correct |
93 |
Correct |
1212 ms |
154340 KB |
Output is correct |
94 |
Correct |
1222 ms |
150720 KB |
Output is correct |
95 |
Correct |
1190 ms |
150864 KB |
Output is correct |
96 |
Correct |
937 ms |
150772 KB |
Output is correct |
97 |
Correct |
939 ms |
151288 KB |
Output is correct |
98 |
Correct |
873 ms |
151448 KB |
Output is correct |
99 |
Correct |
1225 ms |
154460 KB |
Output is correct |
100 |
Correct |
1242 ms |
154136 KB |
Output is correct |
101 |
Correct |
1202 ms |
153768 KB |
Output is correct |
102 |
Correct |
1253 ms |
154260 KB |
Output is correct |
103 |
Correct |
1186 ms |
154180 KB |
Output is correct |
104 |
Correct |
1202 ms |
154332 KB |
Output is correct |
105 |
Correct |
1201 ms |
153672 KB |
Output is correct |
106 |
Correct |
1784 ms |
162824 KB |
Output is correct |
107 |
Correct |
225 ms |
106364 KB |
Output is correct |
108 |
Correct |
234 ms |
106296 KB |
Output is correct |
109 |
Correct |
227 ms |
106324 KB |
Output is correct |
110 |
Correct |
19 ms |
102996 KB |
Output is correct |
111 |
Correct |
19 ms |
102936 KB |
Output is correct |
112 |
Correct |
19 ms |
102932 KB |
Output is correct |
113 |
Correct |
1283 ms |
154384 KB |
Output is correct |
114 |
Correct |
1249 ms |
153864 KB |
Output is correct |
115 |
Correct |
1263 ms |
154512 KB |
Output is correct |
116 |
Correct |
1249 ms |
153952 KB |
Output is correct |
117 |
Correct |
1733 ms |
163132 KB |
Output is correct |
118 |
Correct |
1206 ms |
153908 KB |
Output is correct |
119 |
Correct |
1207 ms |
154400 KB |
Output is correct |
120 |
Correct |
317 ms |
109716 KB |
Output is correct |
121 |
Correct |
336 ms |
109784 KB |
Output is correct |
122 |
Correct |
331 ms |
109648 KB |
Output is correct |
123 |
Correct |
286 ms |
108880 KB |
Output is correct |
124 |
Correct |
292 ms |
108884 KB |
Output is correct |
125 |
Correct |
300 ms |
108928 KB |
Output is correct |
126 |
Correct |
1717 ms |
159832 KB |
Output is correct |
127 |
Correct |
1793 ms |
159064 KB |
Output is correct |
128 |
Correct |
1701 ms |
162296 KB |
Output is correct |
129 |
Correct |
1724 ms |
159656 KB |
Output is correct |
130 |
Correct |
1037 ms |
160036 KB |
Output is correct |
131 |
Correct |
1085 ms |
159060 KB |
Output is correct |
132 |
Correct |
1057 ms |
160184 KB |
Output is correct |
133 |
Correct |
1746 ms |
163144 KB |
Output is correct |
134 |
Correct |
1735 ms |
162216 KB |
Output is correct |
135 |
Correct |
1721 ms |
163072 KB |
Output is correct |
136 |
Correct |
225 ms |
106324 KB |
Output is correct |
137 |
Correct |
224 ms |
106324 KB |
Output is correct |
138 |
Correct |
227 ms |
106324 KB |
Output is correct |