답안 #971479

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
971479 2024-04-28T15:45:09 Z EJIC_B_KEDAX Fish 2 (JOI22_fish2) C++17
100 / 100
1752 ms 77364 KB
#include <bits/stdc++.h>
#include <immintrin.h>

using namespace std;

using ll = long long;
using ld = long double;
#define x first
#define y second
#define all(x) x.begin(), x.end()
#define rall(x) x.rbegin(), x.rend()

mt19937 mt(123);

void solve();
void init();

int32_t main() {
#ifndef LOCAL
    cin.tie(nullptr)->sync_with_stdio(false);
#endif
    cout << fixed << setprecision(30);
    init();
    int t = 1;
    // cin >> t;
    while (t--) {
        solve();
    }
}

void init() {}

const int N = 100100;

struct node {
    vector<ll> sl, sr;
    vector<int> pl, pr, cl, cr;
    node(int a = -1) {
        sl.clear();
        sr.clear();
        pl.clear();
        pr.clear();
        cl.clear();
        cr.clear();
        sl.push_back(a);
        sr.push_back(a);
        pl.push_back(a);
        pr.push_back(a);
        cl.push_back(1);
        cr.push_back(1);
    }
    int cnt() {
        return cl.back();
    }
};

void merge(node& res, node a, node b) {
    res.cl = a.cl;
    res.sl = a.sl;
    res.pl = a.pl;
    res.cr = b.cr;
    res.sr = b.sr;
    res.pr = b.pr;
    ll s = 0;
    int c = 0, x = 0, y = 0;
    while (x < a.pr.size() || y < b.pl.size()) {
        if (y == b.pl.size() || (x < a.pr.size() && a.pr[x] < b.pl[y])) {
            if (s >= a.pr[x]) {
                s += a.sr[x];
                c += a.cr[x];
            } else if (y < b.pl.size()) {
                s += a.sr[x];
                c = a.cr[x];
            } else {
                break;
            }
            x++;
        } else {
            if (s >= b.pl[y]) {
                s += b.sl[y];
                c += b.cl[y];
            } else if (x < a.pr.size()) {
                s += b.sl[y];
                c = b.cl[y];
            } else {
                break;
            }
            y++;
        }
    }
    if (x == a.pr.size() && y == b.pl.size()) {
        res.sl.back() = s;
        res.sr.back() = s;
        res.cl.back() = c;
        res.cr.back() = c;
    } else if (x == a.pr.size()) {
        // res.cl.back() = s;
        // res.sl.back() = c;
        ll ss = s;
        for (int i = 0; i + 1 < a.pl.size(); i++) {
            s += a.sl[i];
        }
        for (; y < b.pl.size(); y++) {
            res.cl.back() = c;
            res.sl.back() = ss;
            if (s < b.pl[y]) {
                res.cl.push_back(0);
                res.sl.push_back(0);
                res.pl.push_back(b.pl[y]);
                ss = 0;
                c = 0;
            }
            s += b.sl[y];
            ss += b.sl[y];
            c += b.cl[y];
        }
        res.cl.back() = c;
        res.sl.back() = ss;
        res.cr.back() = c;
        res.sr.back() = ss;
    } else {
        ll ss = s;
        for (int i = 0; i + 1 < b.pr.size(); i++) {
            s += b.sr[i];
        }
        for (; x < a.pr.size(); x++) {
            res.cr.back() = c;
            res.sr.back() = ss;
            if (s < a.pr[x]) {
                res.cr.push_back(0);
                res.sr.push_back(0);
                res.pr.push_back(a.pr[x]);
                ss = 0;
                c = 0;
            }
            s += a.sr[x];
            ss += a.sr[x];
            c += a.cr[x];
        }
        res.cl.back() = c;
        res.sl.back() = ss;
        res.cr.back() = c;
        res.sr.back() = ss;
    }
}

struct segment_tree {
    vector<node> st;
    size_t size;
    segment_tree(int sz = N) {
        size = sz;
        st.resize(2 * size);
    }
    void update(int i, int x) {
        i += size;
        st[i] = node(x);
        i >>= 1;
        while (i) {
            merge(st[i], st[2 * i], st[2 * i + 1]);
            i >>= 1;
        }
    }
    int get(int l, int r) {
        node res_l, res_r;
        l += size;
        r += size;
        while (l <= r) {
            if (l & 1) {
                if (res_l.sl[0] == -1) {
                    res_l = st[l++];
                } else {
                    merge(res_l, res_l, st[l]);
                    l++;
                }
            }
            if (~r & 1) {
                if (res_r.sl[0] == -1) {
                    res_r = st[r--];
                } else {
                    merge(res_r, st[r], res_r);
                    r--;
                }
            }
            l >>= 1;
            r >>= 1;
        }
        node res;
        merge(res, res_l, res_r);
        return res.cnt();
    }
};

void solve() {
    int n;
    cin >> n;
    segment_tree st(n);
    for (int i = 0; i < n; i++) {
        int x;
        cin >> x;
        st.update(i, x);
    }
    int q;
    cin >> q;
    while (q--) {
        int type;
        cin >> type;
        if (type == 1) {
            int x, y;
            cin >> x >> y; x--;
            st.update(x, y);
        } else {
            int l, r;
            cin >> l >> r; l--; r--;
            cout << st.get(l, r) << '\n';
        }
    }
}

Compilation message

fish2.cpp: In function 'void merge(node&, node, node)':
fish2.cpp:66:14: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   66 |     while (x < a.pr.size() || y < b.pl.size()) {
      |              ^
fish2.cpp:66:33: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   66 |     while (x < a.pr.size() || y < b.pl.size()) {
      |                                 ^
fish2.cpp:67:15: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   67 |         if (y == b.pl.size() || (x < a.pr.size() && a.pr[x] < b.pl[y])) {
      |               ^
fish2.cpp:67:36: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   67 |         if (y == b.pl.size() || (x < a.pr.size() && a.pr[x] < b.pl[y])) {
      |                                    ^
fish2.cpp:71:26: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   71 |             } else if (y < b.pl.size()) {
      |                          ^
fish2.cpp:82:26: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   82 |             } else if (x < a.pr.size()) {
      |                          ^
fish2.cpp:91:11: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   91 |     if (x == a.pr.size() && y == b.pl.size()) {
      |           ^
fish2.cpp:91:31: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   91 |     if (x == a.pr.size() && y == b.pl.size()) {
      |                               ^
fish2.cpp:96:18: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   96 |     } else if (x == a.pr.size()) {
      |                  ^
fish2.cpp:100:31: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  100 |         for (int i = 0; i + 1 < a.pl.size(); i++) {
      |                         ~~~~~~^~~~~~~~~~~~~
fish2.cpp:103:18: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  103 |         for (; y < b.pl.size(); y++) {
      |                  ^
fish2.cpp:123:31: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  123 |         for (int i = 0; i + 1 < b.pr.size(); i++) {
      |                         ~~~~~~^~~~~~~~~~~~~
fish2.cpp:126:18: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  126 |         for (; x < a.pr.size(); x++) {
      |                  ^
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 1 ms 344 KB Output is correct
5 Correct 6 ms 716 KB Output is correct
6 Correct 4 ms 604 KB Output is correct
7 Correct 6 ms 840 KB Output is correct
8 Correct 4 ms 604 KB Output is correct
9 Correct 4 ms 604 KB Output is correct
10 Correct 5 ms 680 KB Output is correct
11 Correct 4 ms 604 KB Output is correct
12 Correct 4 ms 604 KB Output is correct
13 Correct 4 ms 604 KB Output is correct
14 Correct 4 ms 860 KB Output is correct
15 Correct 5 ms 604 KB Output is correct
16 Correct 4 ms 604 KB Output is correct
17 Correct 4 ms 604 KB Output is correct
18 Correct 4 ms 824 KB Output is correct
19 Correct 5 ms 604 KB Output is correct
20 Correct 6 ms 604 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 352 KB Output is correct
2 Correct 638 ms 72796 KB Output is correct
3 Correct 651 ms 72084 KB Output is correct
4 Correct 622 ms 72856 KB Output is correct
5 Correct 702 ms 72188 KB Output is correct
6 Correct 598 ms 69456 KB Output is correct
7 Correct 675 ms 68744 KB Output is correct
8 Correct 597 ms 69300 KB Output is correct
9 Correct 611 ms 68796 KB Output is correct
10 Correct 685 ms 75156 KB Output is correct
11 Correct 667 ms 71676 KB Output is correct
12 Correct 593 ms 68604 KB Output is correct
13 Correct 650 ms 68592 KB Output is correct
14 Correct 619 ms 70220 KB Output is correct
15 Correct 616 ms 70080 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 1 ms 344 KB Output is correct
5 Correct 6 ms 716 KB Output is correct
6 Correct 4 ms 604 KB Output is correct
7 Correct 6 ms 840 KB Output is correct
8 Correct 4 ms 604 KB Output is correct
9 Correct 4 ms 604 KB Output is correct
10 Correct 5 ms 680 KB Output is correct
11 Correct 4 ms 604 KB Output is correct
12 Correct 4 ms 604 KB Output is correct
13 Correct 4 ms 604 KB Output is correct
14 Correct 4 ms 860 KB Output is correct
15 Correct 5 ms 604 KB Output is correct
16 Correct 4 ms 604 KB Output is correct
17 Correct 4 ms 604 KB Output is correct
18 Correct 4 ms 824 KB Output is correct
19 Correct 5 ms 604 KB Output is correct
20 Correct 6 ms 604 KB Output is correct
21 Correct 0 ms 352 KB Output is correct
22 Correct 638 ms 72796 KB Output is correct
23 Correct 651 ms 72084 KB Output is correct
24 Correct 622 ms 72856 KB Output is correct
25 Correct 702 ms 72188 KB Output is correct
26 Correct 598 ms 69456 KB Output is correct
27 Correct 675 ms 68744 KB Output is correct
28 Correct 597 ms 69300 KB Output is correct
29 Correct 611 ms 68796 KB Output is correct
30 Correct 685 ms 75156 KB Output is correct
31 Correct 667 ms 71676 KB Output is correct
32 Correct 593 ms 68604 KB Output is correct
33 Correct 650 ms 68592 KB Output is correct
34 Correct 619 ms 70220 KB Output is correct
35 Correct 616 ms 70080 KB Output is correct
36 Correct 671 ms 73044 KB Output is correct
37 Correct 669 ms 72396 KB Output is correct
38 Correct 668 ms 72176 KB Output is correct
39 Correct 635 ms 72784 KB Output is correct
40 Correct 645 ms 72256 KB Output is correct
41 Correct 609 ms 69220 KB Output is correct
42 Correct 617 ms 69560 KB Output is correct
43 Correct 622 ms 68944 KB Output is correct
44 Correct 633 ms 68944 KB Output is correct
45 Correct 697 ms 74980 KB Output is correct
46 Correct 689 ms 75328 KB Output is correct
47 Correct 653 ms 71008 KB Output is correct
48 Correct 604 ms 68676 KB Output is correct
49 Correct 596 ms 68428 KB Output is correct
50 Correct 679 ms 70224 KB Output is correct
51 Correct 639 ms 70128 KB Output is correct
52 Correct 620 ms 70484 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 352 KB Output is correct
2 Correct 638 ms 72796 KB Output is correct
3 Correct 651 ms 72084 KB Output is correct
4 Correct 622 ms 72856 KB Output is correct
5 Correct 702 ms 72188 KB Output is correct
6 Correct 598 ms 69456 KB Output is correct
7 Correct 675 ms 68744 KB Output is correct
8 Correct 597 ms 69300 KB Output is correct
9 Correct 611 ms 68796 KB Output is correct
10 Correct 685 ms 75156 KB Output is correct
11 Correct 667 ms 71676 KB Output is correct
12 Correct 593 ms 68604 KB Output is correct
13 Correct 650 ms 68592 KB Output is correct
14 Correct 619 ms 70220 KB Output is correct
15 Correct 616 ms 70080 KB Output is correct
16 Correct 1 ms 344 KB Output is correct
17 Correct 1536 ms 74388 KB Output is correct
18 Correct 1525 ms 74836 KB Output is correct
19 Correct 1545 ms 73980 KB Output is correct
20 Correct 1549 ms 73768 KB Output is correct
21 Correct 1495 ms 73772 KB Output is correct
22 Correct 1495 ms 74472 KB Output is correct
23 Correct 1498 ms 73576 KB Output is correct
24 Correct 1528 ms 74140 KB Output is correct
25 Correct 1526 ms 74192 KB Output is correct
26 Correct 1538 ms 74052 KB Output is correct
27 Correct 1353 ms 71252 KB Output is correct
28 Correct 1387 ms 71048 KB Output is correct
29 Correct 1389 ms 71284 KB Output is correct
30 Correct 1552 ms 70508 KB Output is correct
31 Correct 1522 ms 70396 KB Output is correct
32 Correct 1668 ms 73548 KB Output is correct
33 Correct 1752 ms 77072 KB Output is correct
34 Correct 1601 ms 72824 KB Output is correct
35 Correct 1474 ms 72276 KB Output is correct
36 Correct 1714 ms 76872 KB Output is correct
37 Correct 1357 ms 70048 KB Output is correct
38 Correct 1252 ms 70172 KB Output is correct
39 Correct 1406 ms 72308 KB Output is correct
40 Correct 1378 ms 71948 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 352 KB Output is correct
2 Correct 638 ms 72796 KB Output is correct
3 Correct 651 ms 72084 KB Output is correct
4 Correct 622 ms 72856 KB Output is correct
5 Correct 702 ms 72188 KB Output is correct
6 Correct 598 ms 69456 KB Output is correct
7 Correct 675 ms 68744 KB Output is correct
8 Correct 597 ms 69300 KB Output is correct
9 Correct 611 ms 68796 KB Output is correct
10 Correct 685 ms 75156 KB Output is correct
11 Correct 667 ms 71676 KB Output is correct
12 Correct 593 ms 68604 KB Output is correct
13 Correct 650 ms 68592 KB Output is correct
14 Correct 619 ms 70220 KB Output is correct
15 Correct 616 ms 70080 KB Output is correct
16 Correct 0 ms 344 KB Output is correct
17 Correct 1394 ms 74052 KB Output is correct
18 Correct 1547 ms 75448 KB Output is correct
19 Correct 1218 ms 73516 KB Output is correct
20 Correct 1440 ms 74812 KB Output is correct
21 Correct 1338 ms 74052 KB Output is correct
22 Correct 1564 ms 75008 KB Output is correct
23 Correct 1227 ms 73232 KB Output is correct
24 Correct 1509 ms 75148 KB Output is correct
25 Correct 1321 ms 73500 KB Output is correct
26 Correct 1340 ms 71012 KB Output is correct
27 Correct 1377 ms 71072 KB Output is correct
28 Correct 1373 ms 71980 KB Output is correct
29 Correct 1330 ms 71232 KB Output is correct
30 Correct 1391 ms 71348 KB Output is correct
31 Correct 1460 ms 72452 KB Output is correct
32 Correct 1582 ms 74900 KB Output is correct
33 Correct 1224 ms 72920 KB Output is correct
34 Correct 1605 ms 77364 KB Output is correct
35 Correct 1206 ms 77024 KB Output is correct
36 Correct 1490 ms 74320 KB Output is correct
37 Correct 1384 ms 71280 KB Output is correct
38 Correct 1270 ms 71192 KB Output is correct
39 Correct 1339 ms 72376 KB Output is correct
40 Correct 1216 ms 72264 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 1 ms 344 KB Output is correct
5 Correct 6 ms 716 KB Output is correct
6 Correct 4 ms 604 KB Output is correct
7 Correct 6 ms 840 KB Output is correct
8 Correct 4 ms 604 KB Output is correct
9 Correct 4 ms 604 KB Output is correct
10 Correct 5 ms 680 KB Output is correct
11 Correct 4 ms 604 KB Output is correct
12 Correct 4 ms 604 KB Output is correct
13 Correct 4 ms 604 KB Output is correct
14 Correct 4 ms 860 KB Output is correct
15 Correct 5 ms 604 KB Output is correct
16 Correct 4 ms 604 KB Output is correct
17 Correct 4 ms 604 KB Output is correct
18 Correct 4 ms 824 KB Output is correct
19 Correct 5 ms 604 KB Output is correct
20 Correct 6 ms 604 KB Output is correct
21 Correct 0 ms 352 KB Output is correct
22 Correct 638 ms 72796 KB Output is correct
23 Correct 651 ms 72084 KB Output is correct
24 Correct 622 ms 72856 KB Output is correct
25 Correct 702 ms 72188 KB Output is correct
26 Correct 598 ms 69456 KB Output is correct
27 Correct 675 ms 68744 KB Output is correct
28 Correct 597 ms 69300 KB Output is correct
29 Correct 611 ms 68796 KB Output is correct
30 Correct 685 ms 75156 KB Output is correct
31 Correct 667 ms 71676 KB Output is correct
32 Correct 593 ms 68604 KB Output is correct
33 Correct 650 ms 68592 KB Output is correct
34 Correct 619 ms 70220 KB Output is correct
35 Correct 616 ms 70080 KB Output is correct
36 Correct 671 ms 73044 KB Output is correct
37 Correct 669 ms 72396 KB Output is correct
38 Correct 668 ms 72176 KB Output is correct
39 Correct 635 ms 72784 KB Output is correct
40 Correct 645 ms 72256 KB Output is correct
41 Correct 609 ms 69220 KB Output is correct
42 Correct 617 ms 69560 KB Output is correct
43 Correct 622 ms 68944 KB Output is correct
44 Correct 633 ms 68944 KB Output is correct
45 Correct 697 ms 74980 KB Output is correct
46 Correct 689 ms 75328 KB Output is correct
47 Correct 653 ms 71008 KB Output is correct
48 Correct 604 ms 68676 KB Output is correct
49 Correct 596 ms 68428 KB Output is correct
50 Correct 679 ms 70224 KB Output is correct
51 Correct 639 ms 70128 KB Output is correct
52 Correct 620 ms 70484 KB Output is correct
53 Correct 1 ms 344 KB Output is correct
54 Correct 1536 ms 74388 KB Output is correct
55 Correct 1525 ms 74836 KB Output is correct
56 Correct 1545 ms 73980 KB Output is correct
57 Correct 1549 ms 73768 KB Output is correct
58 Correct 1495 ms 73772 KB Output is correct
59 Correct 1495 ms 74472 KB Output is correct
60 Correct 1498 ms 73576 KB Output is correct
61 Correct 1528 ms 74140 KB Output is correct
62 Correct 1526 ms 74192 KB Output is correct
63 Correct 1538 ms 74052 KB Output is correct
64 Correct 1353 ms 71252 KB Output is correct
65 Correct 1387 ms 71048 KB Output is correct
66 Correct 1389 ms 71284 KB Output is correct
67 Correct 1552 ms 70508 KB Output is correct
68 Correct 1522 ms 70396 KB Output is correct
69 Correct 1668 ms 73548 KB Output is correct
70 Correct 1752 ms 77072 KB Output is correct
71 Correct 1601 ms 72824 KB Output is correct
72 Correct 1474 ms 72276 KB Output is correct
73 Correct 1714 ms 76872 KB Output is correct
74 Correct 1357 ms 70048 KB Output is correct
75 Correct 1252 ms 70172 KB Output is correct
76 Correct 1406 ms 72308 KB Output is correct
77 Correct 1378 ms 71948 KB Output is correct
78 Correct 0 ms 344 KB Output is correct
79 Correct 1394 ms 74052 KB Output is correct
80 Correct 1547 ms 75448 KB Output is correct
81 Correct 1218 ms 73516 KB Output is correct
82 Correct 1440 ms 74812 KB Output is correct
83 Correct 1338 ms 74052 KB Output is correct
84 Correct 1564 ms 75008 KB Output is correct
85 Correct 1227 ms 73232 KB Output is correct
86 Correct 1509 ms 75148 KB Output is correct
87 Correct 1321 ms 73500 KB Output is correct
88 Correct 1340 ms 71012 KB Output is correct
89 Correct 1377 ms 71072 KB Output is correct
90 Correct 1373 ms 71980 KB Output is correct
91 Correct 1330 ms 71232 KB Output is correct
92 Correct 1391 ms 71348 KB Output is correct
93 Correct 1460 ms 72452 KB Output is correct
94 Correct 1582 ms 74900 KB Output is correct
95 Correct 1224 ms 72920 KB Output is correct
96 Correct 1605 ms 77364 KB Output is correct
97 Correct 1206 ms 77024 KB Output is correct
98 Correct 1490 ms 74320 KB Output is correct
99 Correct 1384 ms 71280 KB Output is correct
100 Correct 1270 ms 71192 KB Output is correct
101 Correct 1339 ms 72376 KB Output is correct
102 Correct 1216 ms 72264 KB Output is correct
103 Correct 1338 ms 73472 KB Output is correct
104 Correct 1651 ms 75424 KB Output is correct
105 Correct 1507 ms 74020 KB Output is correct
106 Correct 1601 ms 74476 KB Output is correct
107 Correct 1388 ms 73608 KB Output is correct
108 Correct 1613 ms 74788 KB Output is correct
109 Correct 1480 ms 73716 KB Output is correct
110 Correct 1614 ms 75152 KB Output is correct
111 Correct 1507 ms 74036 KB Output is correct
112 Correct 1550 ms 74412 KB Output is correct
113 Correct 1525 ms 71624 KB Output is correct
114 Correct 1418 ms 71236 KB Output is correct
115 Correct 1609 ms 72320 KB Output is correct
116 Correct 1572 ms 72144 KB Output is correct
117 Correct 1460 ms 71712 KB Output is correct
118 Correct 1544 ms 71236 KB Output is correct
119 Correct 1497 ms 71552 KB Output is correct
120 Correct 1607 ms 71968 KB Output is correct
121 Correct 1600 ms 71672 KB Output is correct
122 Correct 1677 ms 74760 KB Output is correct
123 Correct 1295 ms 73080 KB Output is correct
124 Correct 1572 ms 73272 KB Output is correct
125 Correct 1434 ms 72276 KB Output is correct
126 Correct 1611 ms 72912 KB Output is correct
127 Correct 1477 ms 71500 KB Output is correct
128 Correct 1396 ms 70660 KB Output is correct
129 Correct 1490 ms 72620 KB Output is correct
130 Correct 1449 ms 72180 KB Output is correct