Submission #998657

# Submission time Handle Problem Language Result Execution time Memory
998657 2024-06-14T12:39:04 Z vladilius Food Court (JOI21_foodcourt) C++17
100 / 100
421 ms 53584 KB
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pii = pair<int, int>;
using pil = pair<int, ll>;
#define pb push_back
#define ff first
#define ss second
#define ins insert

struct ST{
    struct node{
        ll sum, max_suf;
    };
    using pni = pair<node, int>;
    vector<node> t;
    node null;
    int n;
    ST(int ns){
        n = ns;
        t.resize(4 * n);
        null = {0, 0};
    }
    node merge(node x, node y){
        return {x.sum + y.sum, max(y.max_suf, x.max_suf + y.sum)};
    }
    void upd(int v, int tl, int tr, int& p, int& k){
        if (tl == tr){
            t[v] = {k, k};
            return;
        }
        int tm = (tl + tr) / 2, vv = 2 * v;
        if (p <= tm){
            upd(vv, tl, tm, p, k);
        }
        else {
            upd(vv + 1, tm + 1, tr, p, k);
        }
        t[v] = merge(t[vv], t[vv + 1]);
    }
    void upd(int p, int k){
        upd(1, 1, n, p, k);
    }
    node get(int v, int tl, int tr, int& l, int& r){
        if (l > tr || r < tl) return null;
        if (l <= tl && tr <= r) return t[v];
        int tm = (tl + tr) / 2, vv = 2 * v;
        return merge(get(vv, tl, tm, l, r), get(vv + 1, tm + 1, tr, l, r));
    }
    ll get(int l, int r){
        return get(1, 1, n, l, r).max_suf;
    }
};
 
struct ST1{
    vector<ll> t;
    int n;
    ST1(int ns){
        n = ns;
        t.resize(4 * n);
    }
    void upd(int v, int tl, int tr, int& p, int& k){
        if (tl == tr){
            t[v] = k;
            return;
        }
        int tm = (tl + tr) / 2, vv = 2 * v;
        if (p <= tm){
            upd(vv, tl, tm, p, k);
        }
        else {
            upd(vv + 1, tm + 1, tr, p, k);
        }
        t[v] = t[vv] + t[vv + 1];
    }
    void upd(int p, int k){
        upd(1, 1, n, p, k);
    }
    ll get(int v, int tl, int tr, int& l, int& r){
        if (l > tr || r < tl) return 0;
        if (l <= tl && tr <= r) return t[v];
        int tm = (tl + tr) / 2, vv = 2 * v;
        return get(vv, tl, tm, l, r) + get(vv + 1, tm + 1, tr, l, r);
    }
    ll get(int l, int r){
        return get(1, 1, n, l, r);
    }
    int get_p(int r, ll k){
        int bl = 1, br = r;
        while (bl + 1 < br){
            int m = (bl + br) / 2;
            if (get(1, m) >= k){
                br = m;
            }
            else {
                bl = m + 1;
            }
        }
        if (get(1, bl) >= k) br = bl;
        return br;
    }
};
 
int main(){
    ios_base::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);
    
    int n, m, q; cin>>n>>m>>q;
    vector<pii> st[n + 2];
    vector<pil> qs[n + 1];
    vector<int> col(q + 1);
    for (int tt = 1; tt <= q; tt++){
        int type; cin>>type;
        if (type == 1){
            int l, r, c, k; cin>>l>>r>>c>>k;
            st[l].pb({tt, k});
            st[r + 1].pb({tt, 0});
            col[tt] = c;
        }
        else if (type == 2){
            int l, r, k; cin>>l>>r>>k;
            st[l].pb({tt, -k});
            st[r + 1].pb({tt, 0});
        }
        else {
            int a; ll b; cin>>a>>b;
            qs[a].pb({tt, b});
        }
    }
    ST T(q);
    ST1 Ts(q);
    vector<int> out(q + 1, -1);
    for (int i = 1; i <= n; i++){
        for (auto [j, k]: st[i]){
            T.upd(j, k);
            if (k >= 0) Ts.upd(j, k);
        }
        for (auto [j, b]: qs[i]){
            ll cur = T.get(1, j);
            if (b > cur){
                out[j] = 0;
                continue;
            }
            b = Ts.get(1, j) - cur + b;
            out[j] = col[Ts.get_p(j, b)];
        }
    }
    for (int i = 1; i <= q; i++){
        if (out[i] != -1){
            cout<<out[i]<<"\n";
        }
    }
}
# Verdict Execution time Memory Grader output
1 Correct 1 ms 600 KB Output is correct
2 Correct 2 ms 600 KB Output is correct
3 Correct 1 ms 604 KB Output is correct
4 Correct 3 ms 604 KB Output is correct
5 Correct 1 ms 604 KB Output is correct
6 Correct 1 ms 604 KB Output is correct
7 Correct 2 ms 604 KB Output is correct
8 Correct 1 ms 604 KB Output is correct
9 Correct 2 ms 600 KB Output is correct
10 Correct 2 ms 604 KB Output is correct
11 Correct 2 ms 604 KB Output is correct
12 Correct 1 ms 604 KB Output is correct
13 Correct 1 ms 604 KB Output is correct
14 Correct 1 ms 604 KB Output is correct
15 Correct 1 ms 604 KB Output is correct
16 Correct 1 ms 604 KB Output is correct
17 Correct 1 ms 604 KB Output is correct
18 Correct 2 ms 604 KB Output is correct
19 Correct 1 ms 604 KB Output is correct
20 Correct 1 ms 604 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 600 KB Output is correct
2 Correct 2 ms 600 KB Output is correct
3 Correct 1 ms 604 KB Output is correct
4 Correct 3 ms 604 KB Output is correct
5 Correct 1 ms 604 KB Output is correct
6 Correct 1 ms 604 KB Output is correct
7 Correct 2 ms 604 KB Output is correct
8 Correct 1 ms 604 KB Output is correct
9 Correct 2 ms 600 KB Output is correct
10 Correct 2 ms 604 KB Output is correct
11 Correct 2 ms 604 KB Output is correct
12 Correct 1 ms 604 KB Output is correct
13 Correct 1 ms 604 KB Output is correct
14 Correct 1 ms 604 KB Output is correct
15 Correct 1 ms 604 KB Output is correct
16 Correct 1 ms 604 KB Output is correct
17 Correct 1 ms 604 KB Output is correct
18 Correct 2 ms 604 KB Output is correct
19 Correct 1 ms 604 KB Output is correct
20 Correct 1 ms 604 KB Output is correct
21 Correct 2 ms 604 KB Output is correct
22 Correct 2 ms 856 KB Output is correct
23 Correct 2 ms 604 KB Output is correct
24 Correct 2 ms 860 KB Output is correct
25 Correct 1 ms 604 KB Output is correct
26 Correct 1 ms 604 KB Output is correct
27 Correct 2 ms 860 KB Output is correct
28 Correct 2 ms 860 KB Output is correct
29 Correct 2 ms 724 KB Output is correct
30 Correct 2 ms 856 KB Output is correct
31 Correct 2 ms 860 KB Output is correct
32 Correct 2 ms 860 KB Output is correct
33 Correct 1 ms 608 KB Output is correct
34 Correct 2 ms 860 KB Output is correct
35 Correct 2 ms 760 KB Output is correct
36 Correct 2 ms 860 KB Output is correct
37 Correct 1 ms 604 KB Output is correct
38 Correct 2 ms 604 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 47 ms 12420 KB Output is correct
2 Correct 44 ms 12376 KB Output is correct
3 Correct 46 ms 12372 KB Output is correct
4 Correct 43 ms 12380 KB Output is correct
5 Correct 47 ms 12380 KB Output is correct
6 Correct 43 ms 12380 KB Output is correct
7 Correct 27 ms 7632 KB Output is correct
8 Correct 29 ms 7948 KB Output is correct
9 Correct 49 ms 12380 KB Output is correct
10 Correct 43 ms 12364 KB Output is correct
11 Correct 43 ms 12372 KB Output is correct
12 Correct 43 ms 12380 KB Output is correct
13 Correct 46 ms 10400 KB Output is correct
14 Correct 51 ms 12380 KB Output is correct
15 Correct 45 ms 11140 KB Output is correct
16 Correct 47 ms 12632 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 326 ms 47952 KB Output is correct
2 Correct 251 ms 39252 KB Output is correct
3 Correct 360 ms 52588 KB Output is correct
4 Correct 233 ms 41812 KB Output is correct
5 Correct 236 ms 39212 KB Output is correct
6 Correct 330 ms 52560 KB Output is correct
7 Correct 175 ms 34060 KB Output is correct
8 Correct 184 ms 34208 KB Output is correct
9 Correct 419 ms 52560 KB Output is correct
10 Correct 415 ms 52564 KB Output is correct
11 Correct 320 ms 52564 KB Output is correct
12 Correct 317 ms 52564 KB Output is correct
13 Correct 323 ms 52564 KB Output is correct
14 Correct 325 ms 52552 KB Output is correct
15 Correct 325 ms 52304 KB Output is correct
16 Correct 327 ms 52308 KB Output is correct
17 Correct 340 ms 52304 KB Output is correct
18 Correct 327 ms 52500 KB Output is correct
19 Correct 333 ms 52560 KB Output is correct
20 Correct 329 ms 52368 KB Output is correct
21 Correct 322 ms 52304 KB Output is correct
22 Correct 320 ms 52280 KB Output is correct
23 Correct 331 ms 52304 KB Output is correct
24 Correct 333 ms 52360 KB Output is correct
25 Correct 309 ms 46932 KB Output is correct
26 Correct 329 ms 50512 KB Output is correct
27 Correct 258 ms 51536 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 600 KB Output is correct
2 Correct 2 ms 600 KB Output is correct
3 Correct 1 ms 604 KB Output is correct
4 Correct 3 ms 604 KB Output is correct
5 Correct 1 ms 604 KB Output is correct
6 Correct 1 ms 604 KB Output is correct
7 Correct 2 ms 604 KB Output is correct
8 Correct 1 ms 604 KB Output is correct
9 Correct 2 ms 600 KB Output is correct
10 Correct 2 ms 604 KB Output is correct
11 Correct 2 ms 604 KB Output is correct
12 Correct 1 ms 604 KB Output is correct
13 Correct 1 ms 604 KB Output is correct
14 Correct 1 ms 604 KB Output is correct
15 Correct 1 ms 604 KB Output is correct
16 Correct 1 ms 604 KB Output is correct
17 Correct 1 ms 604 KB Output is correct
18 Correct 2 ms 604 KB Output is correct
19 Correct 1 ms 604 KB Output is correct
20 Correct 1 ms 604 KB Output is correct
21 Correct 47 ms 12420 KB Output is correct
22 Correct 44 ms 12376 KB Output is correct
23 Correct 46 ms 12372 KB Output is correct
24 Correct 43 ms 12380 KB Output is correct
25 Correct 47 ms 12380 KB Output is correct
26 Correct 43 ms 12380 KB Output is correct
27 Correct 27 ms 7632 KB Output is correct
28 Correct 29 ms 7948 KB Output is correct
29 Correct 49 ms 12380 KB Output is correct
30 Correct 43 ms 12364 KB Output is correct
31 Correct 43 ms 12372 KB Output is correct
32 Correct 43 ms 12380 KB Output is correct
33 Correct 46 ms 10400 KB Output is correct
34 Correct 51 ms 12380 KB Output is correct
35 Correct 45 ms 11140 KB Output is correct
36 Correct 47 ms 12632 KB Output is correct
37 Correct 63 ms 11220 KB Output is correct
38 Correct 55 ms 10324 KB Output is correct
39 Correct 28 ms 6608 KB Output is correct
40 Correct 34 ms 7720 KB Output is correct
41 Correct 65 ms 12380 KB Output is correct
42 Correct 68 ms 12388 KB Output is correct
43 Correct 66 ms 12380 KB Output is correct
44 Correct 66 ms 12292 KB Output is correct
45 Correct 66 ms 12376 KB Output is correct
46 Correct 66 ms 12244 KB Output is correct
47 Correct 51 ms 11456 KB Output is correct
48 Correct 64 ms 11868 KB Output is correct
49 Correct 42 ms 8712 KB Output is correct
50 Correct 51 ms 11088 KB Output is correct
51 Correct 61 ms 12380 KB Output is correct
52 Correct 61 ms 12400 KB Output is correct
53 Correct 43 ms 10092 KB Output is correct
54 Correct 48 ms 12368 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 76 ms 12884 KB Output is correct
2 Correct 87 ms 13392 KB Output is correct
3 Correct 89 ms 14200 KB Output is correct
4 Correct 60 ms 10844 KB Output is correct
5 Correct 76 ms 12628 KB Output is correct
6 Correct 88 ms 14164 KB Output is correct
7 Correct 52 ms 8560 KB Output is correct
8 Correct 50 ms 7984 KB Output is correct
9 Correct 71 ms 13132 KB Output is correct
10 Correct 55 ms 10040 KB Output is correct
11 Correct 82 ms 13392 KB Output is correct
12 Correct 88 ms 13392 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 600 KB Output is correct
2 Correct 2 ms 600 KB Output is correct
3 Correct 1 ms 604 KB Output is correct
4 Correct 3 ms 604 KB Output is correct
5 Correct 1 ms 604 KB Output is correct
6 Correct 1 ms 604 KB Output is correct
7 Correct 2 ms 604 KB Output is correct
8 Correct 1 ms 604 KB Output is correct
9 Correct 2 ms 600 KB Output is correct
10 Correct 2 ms 604 KB Output is correct
11 Correct 2 ms 604 KB Output is correct
12 Correct 1 ms 604 KB Output is correct
13 Correct 1 ms 604 KB Output is correct
14 Correct 1 ms 604 KB Output is correct
15 Correct 1 ms 604 KB Output is correct
16 Correct 1 ms 604 KB Output is correct
17 Correct 1 ms 604 KB Output is correct
18 Correct 2 ms 604 KB Output is correct
19 Correct 1 ms 604 KB Output is correct
20 Correct 1 ms 604 KB Output is correct
21 Correct 2 ms 604 KB Output is correct
22 Correct 2 ms 856 KB Output is correct
23 Correct 2 ms 604 KB Output is correct
24 Correct 2 ms 860 KB Output is correct
25 Correct 1 ms 604 KB Output is correct
26 Correct 1 ms 604 KB Output is correct
27 Correct 2 ms 860 KB Output is correct
28 Correct 2 ms 860 KB Output is correct
29 Correct 2 ms 724 KB Output is correct
30 Correct 2 ms 856 KB Output is correct
31 Correct 2 ms 860 KB Output is correct
32 Correct 2 ms 860 KB Output is correct
33 Correct 1 ms 608 KB Output is correct
34 Correct 2 ms 860 KB Output is correct
35 Correct 2 ms 760 KB Output is correct
36 Correct 2 ms 860 KB Output is correct
37 Correct 1 ms 604 KB Output is correct
38 Correct 2 ms 604 KB Output is correct
39 Correct 47 ms 12420 KB Output is correct
40 Correct 44 ms 12376 KB Output is correct
41 Correct 46 ms 12372 KB Output is correct
42 Correct 43 ms 12380 KB Output is correct
43 Correct 47 ms 12380 KB Output is correct
44 Correct 43 ms 12380 KB Output is correct
45 Correct 27 ms 7632 KB Output is correct
46 Correct 29 ms 7948 KB Output is correct
47 Correct 49 ms 12380 KB Output is correct
48 Correct 43 ms 12364 KB Output is correct
49 Correct 43 ms 12372 KB Output is correct
50 Correct 43 ms 12380 KB Output is correct
51 Correct 46 ms 10400 KB Output is correct
52 Correct 51 ms 12380 KB Output is correct
53 Correct 45 ms 11140 KB Output is correct
54 Correct 47 ms 12632 KB Output is correct
55 Correct 63 ms 11220 KB Output is correct
56 Correct 55 ms 10324 KB Output is correct
57 Correct 28 ms 6608 KB Output is correct
58 Correct 34 ms 7720 KB Output is correct
59 Correct 65 ms 12380 KB Output is correct
60 Correct 68 ms 12388 KB Output is correct
61 Correct 66 ms 12380 KB Output is correct
62 Correct 66 ms 12292 KB Output is correct
63 Correct 66 ms 12376 KB Output is correct
64 Correct 66 ms 12244 KB Output is correct
65 Correct 51 ms 11456 KB Output is correct
66 Correct 64 ms 11868 KB Output is correct
67 Correct 42 ms 8712 KB Output is correct
68 Correct 51 ms 11088 KB Output is correct
69 Correct 61 ms 12380 KB Output is correct
70 Correct 61 ms 12400 KB Output is correct
71 Correct 43 ms 10092 KB Output is correct
72 Correct 48 ms 12368 KB Output is correct
73 Correct 76 ms 12884 KB Output is correct
74 Correct 87 ms 13392 KB Output is correct
75 Correct 89 ms 14200 KB Output is correct
76 Correct 60 ms 10844 KB Output is correct
77 Correct 76 ms 12628 KB Output is correct
78 Correct 88 ms 14164 KB Output is correct
79 Correct 52 ms 8560 KB Output is correct
80 Correct 50 ms 7984 KB Output is correct
81 Correct 71 ms 13132 KB Output is correct
82 Correct 55 ms 10040 KB Output is correct
83 Correct 82 ms 13392 KB Output is correct
84 Correct 88 ms 13392 KB Output is correct
85 Correct 83 ms 12292 KB Output is correct
86 Correct 77 ms 13992 KB Output is correct
87 Correct 61 ms 12424 KB Output is correct
88 Correct 71 ms 13912 KB Output is correct
89 Correct 45 ms 9996 KB Output is correct
90 Correct 68 ms 13908 KB Output is correct
91 Correct 55 ms 10884 KB Output is correct
92 Correct 52 ms 10632 KB Output is correct
93 Correct 70 ms 13984 KB Output is correct
94 Correct 70 ms 13908 KB Output is correct
95 Correct 68 ms 13396 KB Output is correct
96 Correct 72 ms 13912 KB Output is correct
97 Correct 69 ms 13904 KB Output is correct
98 Correct 57 ms 11352 KB Output is correct
99 Correct 56 ms 12724 KB Output is correct
100 Correct 57 ms 11100 KB Output is correct
101 Correct 69 ms 13396 KB Output is correct
102 Correct 57 ms 13904 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 600 KB Output is correct
2 Correct 2 ms 600 KB Output is correct
3 Correct 1 ms 604 KB Output is correct
4 Correct 3 ms 604 KB Output is correct
5 Correct 1 ms 604 KB Output is correct
6 Correct 1 ms 604 KB Output is correct
7 Correct 2 ms 604 KB Output is correct
8 Correct 1 ms 604 KB Output is correct
9 Correct 2 ms 600 KB Output is correct
10 Correct 2 ms 604 KB Output is correct
11 Correct 2 ms 604 KB Output is correct
12 Correct 1 ms 604 KB Output is correct
13 Correct 1 ms 604 KB Output is correct
14 Correct 1 ms 604 KB Output is correct
15 Correct 1 ms 604 KB Output is correct
16 Correct 1 ms 604 KB Output is correct
17 Correct 1 ms 604 KB Output is correct
18 Correct 2 ms 604 KB Output is correct
19 Correct 1 ms 604 KB Output is correct
20 Correct 1 ms 604 KB Output is correct
21 Correct 2 ms 604 KB Output is correct
22 Correct 2 ms 856 KB Output is correct
23 Correct 2 ms 604 KB Output is correct
24 Correct 2 ms 860 KB Output is correct
25 Correct 1 ms 604 KB Output is correct
26 Correct 1 ms 604 KB Output is correct
27 Correct 2 ms 860 KB Output is correct
28 Correct 2 ms 860 KB Output is correct
29 Correct 2 ms 724 KB Output is correct
30 Correct 2 ms 856 KB Output is correct
31 Correct 2 ms 860 KB Output is correct
32 Correct 2 ms 860 KB Output is correct
33 Correct 1 ms 608 KB Output is correct
34 Correct 2 ms 860 KB Output is correct
35 Correct 2 ms 760 KB Output is correct
36 Correct 2 ms 860 KB Output is correct
37 Correct 1 ms 604 KB Output is correct
38 Correct 2 ms 604 KB Output is correct
39 Correct 47 ms 12420 KB Output is correct
40 Correct 44 ms 12376 KB Output is correct
41 Correct 46 ms 12372 KB Output is correct
42 Correct 43 ms 12380 KB Output is correct
43 Correct 47 ms 12380 KB Output is correct
44 Correct 43 ms 12380 KB Output is correct
45 Correct 27 ms 7632 KB Output is correct
46 Correct 29 ms 7948 KB Output is correct
47 Correct 49 ms 12380 KB Output is correct
48 Correct 43 ms 12364 KB Output is correct
49 Correct 43 ms 12372 KB Output is correct
50 Correct 43 ms 12380 KB Output is correct
51 Correct 46 ms 10400 KB Output is correct
52 Correct 51 ms 12380 KB Output is correct
53 Correct 45 ms 11140 KB Output is correct
54 Correct 47 ms 12632 KB Output is correct
55 Correct 326 ms 47952 KB Output is correct
56 Correct 251 ms 39252 KB Output is correct
57 Correct 360 ms 52588 KB Output is correct
58 Correct 233 ms 41812 KB Output is correct
59 Correct 236 ms 39212 KB Output is correct
60 Correct 330 ms 52560 KB Output is correct
61 Correct 175 ms 34060 KB Output is correct
62 Correct 184 ms 34208 KB Output is correct
63 Correct 419 ms 52560 KB Output is correct
64 Correct 415 ms 52564 KB Output is correct
65 Correct 320 ms 52564 KB Output is correct
66 Correct 317 ms 52564 KB Output is correct
67 Correct 323 ms 52564 KB Output is correct
68 Correct 325 ms 52552 KB Output is correct
69 Correct 325 ms 52304 KB Output is correct
70 Correct 327 ms 52308 KB Output is correct
71 Correct 340 ms 52304 KB Output is correct
72 Correct 327 ms 52500 KB Output is correct
73 Correct 333 ms 52560 KB Output is correct
74 Correct 329 ms 52368 KB Output is correct
75 Correct 322 ms 52304 KB Output is correct
76 Correct 320 ms 52280 KB Output is correct
77 Correct 331 ms 52304 KB Output is correct
78 Correct 333 ms 52360 KB Output is correct
79 Correct 309 ms 46932 KB Output is correct
80 Correct 329 ms 50512 KB Output is correct
81 Correct 258 ms 51536 KB Output is correct
82 Correct 63 ms 11220 KB Output is correct
83 Correct 55 ms 10324 KB Output is correct
84 Correct 28 ms 6608 KB Output is correct
85 Correct 34 ms 7720 KB Output is correct
86 Correct 65 ms 12380 KB Output is correct
87 Correct 68 ms 12388 KB Output is correct
88 Correct 66 ms 12380 KB Output is correct
89 Correct 66 ms 12292 KB Output is correct
90 Correct 66 ms 12376 KB Output is correct
91 Correct 66 ms 12244 KB Output is correct
92 Correct 51 ms 11456 KB Output is correct
93 Correct 64 ms 11868 KB Output is correct
94 Correct 42 ms 8712 KB Output is correct
95 Correct 51 ms 11088 KB Output is correct
96 Correct 61 ms 12380 KB Output is correct
97 Correct 61 ms 12400 KB Output is correct
98 Correct 43 ms 10092 KB Output is correct
99 Correct 48 ms 12368 KB Output is correct
100 Correct 76 ms 12884 KB Output is correct
101 Correct 87 ms 13392 KB Output is correct
102 Correct 89 ms 14200 KB Output is correct
103 Correct 60 ms 10844 KB Output is correct
104 Correct 76 ms 12628 KB Output is correct
105 Correct 88 ms 14164 KB Output is correct
106 Correct 52 ms 8560 KB Output is correct
107 Correct 50 ms 7984 KB Output is correct
108 Correct 71 ms 13132 KB Output is correct
109 Correct 55 ms 10040 KB Output is correct
110 Correct 82 ms 13392 KB Output is correct
111 Correct 88 ms 13392 KB Output is correct
112 Correct 83 ms 12292 KB Output is correct
113 Correct 77 ms 13992 KB Output is correct
114 Correct 61 ms 12424 KB Output is correct
115 Correct 71 ms 13912 KB Output is correct
116 Correct 45 ms 9996 KB Output is correct
117 Correct 68 ms 13908 KB Output is correct
118 Correct 55 ms 10884 KB Output is correct
119 Correct 52 ms 10632 KB Output is correct
120 Correct 70 ms 13984 KB Output is correct
121 Correct 70 ms 13908 KB Output is correct
122 Correct 68 ms 13396 KB Output is correct
123 Correct 72 ms 13912 KB Output is correct
124 Correct 69 ms 13904 KB Output is correct
125 Correct 57 ms 11352 KB Output is correct
126 Correct 56 ms 12724 KB Output is correct
127 Correct 57 ms 11100 KB Output is correct
128 Correct 69 ms 13396 KB Output is correct
129 Correct 57 ms 13904 KB Output is correct
130 Correct 348 ms 52728 KB Output is correct
131 Correct 245 ms 38924 KB Output is correct
132 Correct 345 ms 53072 KB Output is correct
133 Correct 317 ms 51016 KB Output is correct
134 Correct 274 ms 46876 KB Output is correct
135 Correct 340 ms 53332 KB Output is correct
136 Correct 411 ms 53584 KB Output is correct
137 Correct 421 ms 53400 KB Output is correct
138 Correct 323 ms 53180 KB Output is correct
139 Correct 334 ms 53092 KB Output is correct
140 Correct 317 ms 53328 KB Output is correct
141 Correct 335 ms 53076 KB Output is correct
142 Correct 338 ms 53096 KB Output is correct
143 Correct 331 ms 53076 KB Output is correct
144 Correct 330 ms 53076 KB Output is correct
145 Correct 326 ms 53132 KB Output is correct
146 Correct 330 ms 53048 KB Output is correct
147 Correct 330 ms 52940 KB Output is correct
148 Correct 333 ms 53072 KB Output is correct
149 Correct 335 ms 52996 KB Output is correct
150 Correct 255 ms 48560 KB Output is correct
151 Correct 331 ms 51028 KB Output is correct
152 Correct 323 ms 50992 KB Output is correct
153 Correct 262 ms 52564 KB Output is correct