Submission #891189

# Submission time Handle Problem Language Result Execution time Memory
891189 2023-12-22T10:39:01 Z LucaIlie Food Court (JOI21_foodcourt) C++17
89 / 100
1000 ms 108876 KB
#include <bits/stdc++.h>

using namespace std;

struct aaa {
    int t;
    long long k;
};

const int MAX_N = 3e5;
int group[MAX_N];

struct SegTree {
    struct info {
        long long tot, sum, minn;

        info operator+( info &x ) {
            info ans;

            ans.tot = tot + x.tot;
            ans.minn = min( minn, sum + x.minn );
            ans.sum = sum + x.sum;

            return ans;
        }
    };

    info lazy[4 * MAX_N];
    long long size[4 * MAX_N];
    vector<aaa> q[4 * MAX_N];

    void propag( int v, int l, int r ) {
        if ( l != r ) {
            lazy[v * 2 + 1] = lazy[v * 2 + 1] + lazy[v];
            lazy[v * 2 + 2] = lazy[v * 2 + 2] + lazy[v];
            lazy[v] = { 0, 0 };
        }
    }

    void init( int v, int l, int r ) {
        q[v].push_back( { -1, 0 } );
        if ( l == r )
            return;
        int mid = (l + r) / 2;
        init( v * 2 + 1, l, mid );
        init( v * 2 + 2, mid + 1, r );
    }
    void update( int v, int l, int r, int lu, int ru, int k, int t ) {
        propag( v, l, r );

        if ( l > ru || r < lu )
            return;

        if ( lu <= l && r <= ru ) {
            if ( k > 0 ) {
                size[v] += k;
                q[v].push_back( { t, size[v] } );
            }
            info add = { max( k, 0 ), k,  min( k, 0 ) };
            lazy[v] = lazy[v] + add;
            propag( v, l, r );
            return;
        }

        int mid = (l + r) / 2;
        update( v * 2 + 1, l, mid, lu, ru, k, t );
        update( v * 2 + 2, mid + 1, r, lu, ru, k, t );
    }

    vector<int> ans;
    long long tot = 0;
    long long query( int v, int l, int r, int p ) {
        if ( v == 0 )
            ans.clear();
        ans.push_back( v );
        propag( v, l, r );

        if ( l == r ) {
            tot = lazy[v].tot;
            return lazy[v].tot - (lazy[v].sum - lazy[v].minn);
        }

        int mid = (l + r) / 2;
        if ( p <= mid )
            return query( v * 2 + 1, l, mid, p );
        return query( v * 2 + 2, mid + 1, r, p );
    }
} qs;

signed main() {
    ios_base::sync_with_stdio( false );
    cin.tie( NULL );
    cout.tie( NULL );

    int n, m, q;

    cin >> n >> m >> q;
    qs.init( 0, 1, n );
    for ( int t = 0; t < q; t++ ) {
        int type;

        cin >> type;
        if ( type == 1 ) {
            int l, r, c, k;
            cin >> l >> r >> c >> k;
            qs.update( 0, 1, n, l, r, k, t );
            group[t] = c;
        } else if ( type == 2 ) {
            int l, r, k;
            cin >> l >> r >> k;
            qs.update( 0, 1, n, l, r, -k, t );
        } else {
            int p;
            long long x;
            cin >> p >> x;
            x += qs.query( 0, 1, n, p );
            vector<int> vert = qs.ans;

            if ( m == 1 ) {
                cout << (x <= qs.tot) << "\n";
                continue;
            }

            int l = -1, r = t;
            while ( r - l > 1 ) {
                int mid = (l + r) / 2;

                long long k = 0;
                for ( int v: vert ) {
                    int lp = 0, rp = qs.q[v].size();
                    while ( rp - lp > 1 ) {
                        int mp = (lp + rp) / 2;
                        if ( qs.q[v][mp].t > mid )
                            rp = mp;
                        else
                            lp = mp;
                    }
                    k += qs.q[v][lp].k;
                }

                if ( k >= x )
                    r = mid;
                else
                    l = mid;
            }

            cout << group[r] << "\n";
        }
    }

    return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 8 ms 29532 KB Output is correct
2 Correct 9 ms 29404 KB Output is correct
3 Correct 8 ms 29532 KB Output is correct
4 Correct 9 ms 29640 KB Output is correct
5 Correct 7 ms 29020 KB Output is correct
6 Correct 7 ms 29020 KB Output is correct
7 Correct 9 ms 29532 KB Output is correct
8 Correct 9 ms 29528 KB Output is correct
9 Correct 8 ms 29532 KB Output is correct
10 Correct 9 ms 29532 KB Output is correct
11 Correct 9 ms 29532 KB Output is correct
12 Correct 9 ms 29532 KB Output is correct
13 Correct 7 ms 29276 KB Output is correct
14 Correct 7 ms 29276 KB Output is correct
15 Correct 7 ms 29532 KB Output is correct
16 Correct 8 ms 29532 KB Output is correct
17 Correct 9 ms 29532 KB Output is correct
18 Correct 8 ms 29532 KB Output is correct
19 Correct 8 ms 29528 KB Output is correct
20 Correct 8 ms 29380 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 8 ms 29532 KB Output is correct
2 Correct 9 ms 29404 KB Output is correct
3 Correct 8 ms 29532 KB Output is correct
4 Correct 9 ms 29640 KB Output is correct
5 Correct 7 ms 29020 KB Output is correct
6 Correct 7 ms 29020 KB Output is correct
7 Correct 9 ms 29532 KB Output is correct
8 Correct 9 ms 29528 KB Output is correct
9 Correct 8 ms 29532 KB Output is correct
10 Correct 9 ms 29532 KB Output is correct
11 Correct 9 ms 29532 KB Output is correct
12 Correct 9 ms 29532 KB Output is correct
13 Correct 7 ms 29276 KB Output is correct
14 Correct 7 ms 29276 KB Output is correct
15 Correct 7 ms 29532 KB Output is correct
16 Correct 8 ms 29532 KB Output is correct
17 Correct 9 ms 29532 KB Output is correct
18 Correct 8 ms 29532 KB Output is correct
19 Correct 8 ms 29528 KB Output is correct
20 Correct 8 ms 29380 KB Output is correct
21 Correct 9 ms 29532 KB Output is correct
22 Correct 9 ms 29392 KB Output is correct
23 Correct 9 ms 29532 KB Output is correct
24 Correct 9 ms 29532 KB Output is correct
25 Correct 7 ms 29020 KB Output is correct
26 Correct 8 ms 29020 KB Output is correct
27 Correct 9 ms 29528 KB Output is correct
28 Correct 9 ms 29532 KB Output is correct
29 Correct 9 ms 29532 KB Output is correct
30 Correct 9 ms 29532 KB Output is correct
31 Correct 9 ms 29532 KB Output is correct
32 Correct 9 ms 29404 KB Output is correct
33 Correct 7 ms 29272 KB Output is correct
34 Correct 7 ms 29276 KB Output is correct
35 Correct 8 ms 29532 KB Output is correct
36 Correct 8 ms 29532 KB Output is correct
37 Correct 8 ms 29532 KB Output is correct
38 Correct 8 ms 29532 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 87 ms 39244 KB Output is correct
2 Correct 80 ms 39760 KB Output is correct
3 Correct 84 ms 39636 KB Output is correct
4 Correct 86 ms 39760 KB Output is correct
5 Correct 97 ms 40656 KB Output is correct
6 Correct 86 ms 40476 KB Output is correct
7 Correct 38 ms 29876 KB Output is correct
8 Correct 50 ms 29812 KB Output is correct
9 Correct 77 ms 39268 KB Output is correct
10 Correct 79 ms 39248 KB Output is correct
11 Correct 81 ms 39268 KB Output is correct
12 Correct 79 ms 39300 KB Output is correct
13 Correct 73 ms 38512 KB Output is correct
14 Correct 87 ms 40272 KB Output is correct
15 Correct 80 ms 40016 KB Output is correct
16 Correct 79 ms 41296 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 479 ms 87920 KB Output is correct
2 Correct 440 ms 79468 KB Output is correct
3 Correct 544 ms 92844 KB Output is correct
4 Correct 468 ms 95524 KB Output is correct
5 Correct 432 ms 91504 KB Output is correct
6 Correct 595 ms 108876 KB Output is correct
7 Correct 66 ms 32084 KB Output is correct
8 Correct 70 ms 31808 KB Output is correct
9 Correct 549 ms 107672 KB Output is correct
10 Correct 534 ms 107512 KB Output is correct
11 Correct 482 ms 97000 KB Output is correct
12 Correct 528 ms 97468 KB Output is correct
13 Correct 518 ms 97292 KB Output is correct
14 Correct 544 ms 97316 KB Output is correct
15 Correct 543 ms 97892 KB Output is correct
16 Correct 557 ms 97404 KB Output is correct
17 Correct 563 ms 97308 KB Output is correct
18 Correct 530 ms 96964 KB Output is correct
19 Correct 535 ms 97628 KB Output is correct
20 Correct 532 ms 97184 KB Output is correct
21 Correct 549 ms 97284 KB Output is correct
22 Correct 556 ms 97400 KB Output is correct
23 Correct 568 ms 97824 KB Output is correct
24 Correct 546 ms 97320 KB Output is correct
25 Correct 320 ms 87580 KB Output is correct
26 Correct 324 ms 93964 KB Output is correct
27 Correct 386 ms 82884 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 8 ms 29532 KB Output is correct
2 Correct 9 ms 29404 KB Output is correct
3 Correct 8 ms 29532 KB Output is correct
4 Correct 9 ms 29640 KB Output is correct
5 Correct 7 ms 29020 KB Output is correct
6 Correct 7 ms 29020 KB Output is correct
7 Correct 9 ms 29532 KB Output is correct
8 Correct 9 ms 29528 KB Output is correct
9 Correct 8 ms 29532 KB Output is correct
10 Correct 9 ms 29532 KB Output is correct
11 Correct 9 ms 29532 KB Output is correct
12 Correct 9 ms 29532 KB Output is correct
13 Correct 7 ms 29276 KB Output is correct
14 Correct 7 ms 29276 KB Output is correct
15 Correct 7 ms 29532 KB Output is correct
16 Correct 8 ms 29532 KB Output is correct
17 Correct 9 ms 29532 KB Output is correct
18 Correct 8 ms 29532 KB Output is correct
19 Correct 8 ms 29528 KB Output is correct
20 Correct 8 ms 29380 KB Output is correct
21 Correct 87 ms 39244 KB Output is correct
22 Correct 80 ms 39760 KB Output is correct
23 Correct 84 ms 39636 KB Output is correct
24 Correct 86 ms 39760 KB Output is correct
25 Correct 97 ms 40656 KB Output is correct
26 Correct 86 ms 40476 KB Output is correct
27 Correct 38 ms 29876 KB Output is correct
28 Correct 50 ms 29812 KB Output is correct
29 Correct 77 ms 39268 KB Output is correct
30 Correct 79 ms 39248 KB Output is correct
31 Correct 81 ms 39268 KB Output is correct
32 Correct 79 ms 39300 KB Output is correct
33 Correct 73 ms 38512 KB Output is correct
34 Correct 87 ms 40272 KB Output is correct
35 Correct 80 ms 40016 KB Output is correct
36 Correct 79 ms 41296 KB Output is correct
37 Correct 184 ms 43496 KB Output is correct
38 Correct 154 ms 45592 KB Output is correct
39 Correct 30 ms 29920 KB Output is correct
40 Correct 43 ms 29940 KB Output is correct
41 Correct 184 ms 45652 KB Output is correct
42 Correct 185 ms 45888 KB Output is correct
43 Correct 192 ms 45892 KB Output is correct
44 Correct 198 ms 45932 KB Output is correct
45 Correct 182 ms 45920 KB Output is correct
46 Correct 186 ms 45892 KB Output is correct
47 Correct 67 ms 37076 KB Output is correct
48 Correct 125 ms 45628 KB Output is correct
49 Correct 111 ms 42032 KB Output is correct
50 Correct 149 ms 44620 KB Output is correct
51 Correct 192 ms 45980 KB Output is correct
52 Correct 177 ms 46152 KB Output is correct
53 Correct 67 ms 40020 KB Output is correct
54 Correct 84 ms 41300 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 242 ms 46420 KB Output is correct
2 Correct 267 ms 46632 KB Output is correct
3 Correct 275 ms 47960 KB Output is correct
4 Correct 193 ms 45032 KB Output is correct
5 Correct 237 ms 46780 KB Output is correct
6 Correct 289 ms 48452 KB Output is correct
7 Correct 55 ms 29936 KB Output is correct
8 Correct 68 ms 29944 KB Output is correct
9 Correct 105 ms 37204 KB Output is correct
10 Correct 115 ms 44432 KB Output is correct
11 Correct 153 ms 48924 KB Output is correct
12 Correct 152 ms 48640 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 8 ms 29532 KB Output is correct
2 Correct 9 ms 29404 KB Output is correct
3 Correct 8 ms 29532 KB Output is correct
4 Correct 9 ms 29640 KB Output is correct
5 Correct 7 ms 29020 KB Output is correct
6 Correct 7 ms 29020 KB Output is correct
7 Correct 9 ms 29532 KB Output is correct
8 Correct 9 ms 29528 KB Output is correct
9 Correct 8 ms 29532 KB Output is correct
10 Correct 9 ms 29532 KB Output is correct
11 Correct 9 ms 29532 KB Output is correct
12 Correct 9 ms 29532 KB Output is correct
13 Correct 7 ms 29276 KB Output is correct
14 Correct 7 ms 29276 KB Output is correct
15 Correct 7 ms 29532 KB Output is correct
16 Correct 8 ms 29532 KB Output is correct
17 Correct 9 ms 29532 KB Output is correct
18 Correct 8 ms 29532 KB Output is correct
19 Correct 8 ms 29528 KB Output is correct
20 Correct 8 ms 29380 KB Output is correct
21 Correct 9 ms 29532 KB Output is correct
22 Correct 9 ms 29392 KB Output is correct
23 Correct 9 ms 29532 KB Output is correct
24 Correct 9 ms 29532 KB Output is correct
25 Correct 7 ms 29020 KB Output is correct
26 Correct 8 ms 29020 KB Output is correct
27 Correct 9 ms 29528 KB Output is correct
28 Correct 9 ms 29532 KB Output is correct
29 Correct 9 ms 29532 KB Output is correct
30 Correct 9 ms 29532 KB Output is correct
31 Correct 9 ms 29532 KB Output is correct
32 Correct 9 ms 29404 KB Output is correct
33 Correct 7 ms 29272 KB Output is correct
34 Correct 7 ms 29276 KB Output is correct
35 Correct 8 ms 29532 KB Output is correct
36 Correct 8 ms 29532 KB Output is correct
37 Correct 8 ms 29532 KB Output is correct
38 Correct 8 ms 29532 KB Output is correct
39 Correct 87 ms 39244 KB Output is correct
40 Correct 80 ms 39760 KB Output is correct
41 Correct 84 ms 39636 KB Output is correct
42 Correct 86 ms 39760 KB Output is correct
43 Correct 97 ms 40656 KB Output is correct
44 Correct 86 ms 40476 KB Output is correct
45 Correct 38 ms 29876 KB Output is correct
46 Correct 50 ms 29812 KB Output is correct
47 Correct 77 ms 39268 KB Output is correct
48 Correct 79 ms 39248 KB Output is correct
49 Correct 81 ms 39268 KB Output is correct
50 Correct 79 ms 39300 KB Output is correct
51 Correct 73 ms 38512 KB Output is correct
52 Correct 87 ms 40272 KB Output is correct
53 Correct 80 ms 40016 KB Output is correct
54 Correct 79 ms 41296 KB Output is correct
55 Correct 184 ms 43496 KB Output is correct
56 Correct 154 ms 45592 KB Output is correct
57 Correct 30 ms 29920 KB Output is correct
58 Correct 43 ms 29940 KB Output is correct
59 Correct 184 ms 45652 KB Output is correct
60 Correct 185 ms 45888 KB Output is correct
61 Correct 192 ms 45892 KB Output is correct
62 Correct 198 ms 45932 KB Output is correct
63 Correct 182 ms 45920 KB Output is correct
64 Correct 186 ms 45892 KB Output is correct
65 Correct 67 ms 37076 KB Output is correct
66 Correct 125 ms 45628 KB Output is correct
67 Correct 111 ms 42032 KB Output is correct
68 Correct 149 ms 44620 KB Output is correct
69 Correct 192 ms 45980 KB Output is correct
70 Correct 177 ms 46152 KB Output is correct
71 Correct 67 ms 40020 KB Output is correct
72 Correct 84 ms 41300 KB Output is correct
73 Correct 242 ms 46420 KB Output is correct
74 Correct 267 ms 46632 KB Output is correct
75 Correct 275 ms 47960 KB Output is correct
76 Correct 193 ms 45032 KB Output is correct
77 Correct 237 ms 46780 KB Output is correct
78 Correct 289 ms 48452 KB Output is correct
79 Correct 55 ms 29936 KB Output is correct
80 Correct 68 ms 29944 KB Output is correct
81 Correct 105 ms 37204 KB Output is correct
82 Correct 115 ms 44432 KB Output is correct
83 Correct 153 ms 48924 KB Output is correct
84 Correct 152 ms 48640 KB Output is correct
85 Correct 214 ms 42864 KB Output is correct
86 Correct 214 ms 45140 KB Output is correct
87 Correct 168 ms 46728 KB Output is correct
88 Correct 200 ms 48408 KB Output is correct
89 Correct 119 ms 41928 KB Output is correct
90 Correct 196 ms 45888 KB Output is correct
91 Correct 143 ms 42568 KB Output is correct
92 Correct 136 ms 42316 KB Output is correct
93 Correct 186 ms 45796 KB Output is correct
94 Correct 185 ms 45820 KB Output is correct
95 Correct 179 ms 45280 KB Output is correct
96 Correct 186 ms 45892 KB Output is correct
97 Correct 191 ms 45924 KB Output is correct
98 Correct 151 ms 43248 KB Output is correct
99 Correct 70 ms 37072 KB Output is correct
100 Correct 101 ms 42756 KB Output is correct
101 Correct 120 ms 45448 KB Output is correct
102 Correct 120 ms 42476 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 8 ms 29532 KB Output is correct
2 Correct 9 ms 29404 KB Output is correct
3 Correct 8 ms 29532 KB Output is correct
4 Correct 9 ms 29640 KB Output is correct
5 Correct 7 ms 29020 KB Output is correct
6 Correct 7 ms 29020 KB Output is correct
7 Correct 9 ms 29532 KB Output is correct
8 Correct 9 ms 29528 KB Output is correct
9 Correct 8 ms 29532 KB Output is correct
10 Correct 9 ms 29532 KB Output is correct
11 Correct 9 ms 29532 KB Output is correct
12 Correct 9 ms 29532 KB Output is correct
13 Correct 7 ms 29276 KB Output is correct
14 Correct 7 ms 29276 KB Output is correct
15 Correct 7 ms 29532 KB Output is correct
16 Correct 8 ms 29532 KB Output is correct
17 Correct 9 ms 29532 KB Output is correct
18 Correct 8 ms 29532 KB Output is correct
19 Correct 8 ms 29528 KB Output is correct
20 Correct 8 ms 29380 KB Output is correct
21 Correct 9 ms 29532 KB Output is correct
22 Correct 9 ms 29392 KB Output is correct
23 Correct 9 ms 29532 KB Output is correct
24 Correct 9 ms 29532 KB Output is correct
25 Correct 7 ms 29020 KB Output is correct
26 Correct 8 ms 29020 KB Output is correct
27 Correct 9 ms 29528 KB Output is correct
28 Correct 9 ms 29532 KB Output is correct
29 Correct 9 ms 29532 KB Output is correct
30 Correct 9 ms 29532 KB Output is correct
31 Correct 9 ms 29532 KB Output is correct
32 Correct 9 ms 29404 KB Output is correct
33 Correct 7 ms 29272 KB Output is correct
34 Correct 7 ms 29276 KB Output is correct
35 Correct 8 ms 29532 KB Output is correct
36 Correct 8 ms 29532 KB Output is correct
37 Correct 8 ms 29532 KB Output is correct
38 Correct 8 ms 29532 KB Output is correct
39 Correct 87 ms 39244 KB Output is correct
40 Correct 80 ms 39760 KB Output is correct
41 Correct 84 ms 39636 KB Output is correct
42 Correct 86 ms 39760 KB Output is correct
43 Correct 97 ms 40656 KB Output is correct
44 Correct 86 ms 40476 KB Output is correct
45 Correct 38 ms 29876 KB Output is correct
46 Correct 50 ms 29812 KB Output is correct
47 Correct 77 ms 39268 KB Output is correct
48 Correct 79 ms 39248 KB Output is correct
49 Correct 81 ms 39268 KB Output is correct
50 Correct 79 ms 39300 KB Output is correct
51 Correct 73 ms 38512 KB Output is correct
52 Correct 87 ms 40272 KB Output is correct
53 Correct 80 ms 40016 KB Output is correct
54 Correct 79 ms 41296 KB Output is correct
55 Correct 479 ms 87920 KB Output is correct
56 Correct 440 ms 79468 KB Output is correct
57 Correct 544 ms 92844 KB Output is correct
58 Correct 468 ms 95524 KB Output is correct
59 Correct 432 ms 91504 KB Output is correct
60 Correct 595 ms 108876 KB Output is correct
61 Correct 66 ms 32084 KB Output is correct
62 Correct 70 ms 31808 KB Output is correct
63 Correct 549 ms 107672 KB Output is correct
64 Correct 534 ms 107512 KB Output is correct
65 Correct 482 ms 97000 KB Output is correct
66 Correct 528 ms 97468 KB Output is correct
67 Correct 518 ms 97292 KB Output is correct
68 Correct 544 ms 97316 KB Output is correct
69 Correct 543 ms 97892 KB Output is correct
70 Correct 557 ms 97404 KB Output is correct
71 Correct 563 ms 97308 KB Output is correct
72 Correct 530 ms 96964 KB Output is correct
73 Correct 535 ms 97628 KB Output is correct
74 Correct 532 ms 97184 KB Output is correct
75 Correct 549 ms 97284 KB Output is correct
76 Correct 556 ms 97400 KB Output is correct
77 Correct 568 ms 97824 KB Output is correct
78 Correct 546 ms 97320 KB Output is correct
79 Correct 320 ms 87580 KB Output is correct
80 Correct 324 ms 93964 KB Output is correct
81 Correct 386 ms 82884 KB Output is correct
82 Correct 184 ms 43496 KB Output is correct
83 Correct 154 ms 45592 KB Output is correct
84 Correct 30 ms 29920 KB Output is correct
85 Correct 43 ms 29940 KB Output is correct
86 Correct 184 ms 45652 KB Output is correct
87 Correct 185 ms 45888 KB Output is correct
88 Correct 192 ms 45892 KB Output is correct
89 Correct 198 ms 45932 KB Output is correct
90 Correct 182 ms 45920 KB Output is correct
91 Correct 186 ms 45892 KB Output is correct
92 Correct 67 ms 37076 KB Output is correct
93 Correct 125 ms 45628 KB Output is correct
94 Correct 111 ms 42032 KB Output is correct
95 Correct 149 ms 44620 KB Output is correct
96 Correct 192 ms 45980 KB Output is correct
97 Correct 177 ms 46152 KB Output is correct
98 Correct 67 ms 40020 KB Output is correct
99 Correct 84 ms 41300 KB Output is correct
100 Correct 242 ms 46420 KB Output is correct
101 Correct 267 ms 46632 KB Output is correct
102 Correct 275 ms 47960 KB Output is correct
103 Correct 193 ms 45032 KB Output is correct
104 Correct 237 ms 46780 KB Output is correct
105 Correct 289 ms 48452 KB Output is correct
106 Correct 55 ms 29936 KB Output is correct
107 Correct 68 ms 29944 KB Output is correct
108 Correct 105 ms 37204 KB Output is correct
109 Correct 115 ms 44432 KB Output is correct
110 Correct 153 ms 48924 KB Output is correct
111 Correct 152 ms 48640 KB Output is correct
112 Correct 214 ms 42864 KB Output is correct
113 Correct 214 ms 45140 KB Output is correct
114 Correct 168 ms 46728 KB Output is correct
115 Correct 200 ms 48408 KB Output is correct
116 Correct 119 ms 41928 KB Output is correct
117 Correct 196 ms 45888 KB Output is correct
118 Correct 143 ms 42568 KB Output is correct
119 Correct 136 ms 42316 KB Output is correct
120 Correct 186 ms 45796 KB Output is correct
121 Correct 185 ms 45820 KB Output is correct
122 Correct 179 ms 45280 KB Output is correct
123 Correct 186 ms 45892 KB Output is correct
124 Correct 191 ms 45924 KB Output is correct
125 Correct 151 ms 43248 KB Output is correct
126 Correct 70 ms 37072 KB Output is correct
127 Correct 101 ms 42756 KB Output is correct
128 Correct 120 ms 45448 KB Output is correct
129 Correct 120 ms 42476 KB Output is correct
130 Execution timed out 1051 ms 89512 KB Time limit exceeded
131 Halted 0 ms 0 KB -