Submission #603091

# Submission time Handle Problem Language Result Execution time Memory
603091 2022-07-23T15:13:04 Z FatihSolak Fountain Parks (IOI21_parks) C++17
70 / 100
1885 ms 128156 KB
#include "parks.h"
#include <bits/stdc++.h>
#define N 200005
using namespace std;
int par[N];
int find(int a){
    if(a == par[a])return a;
    return par[a] = find(par[a]);
}
bool merge(int a,int b){
    a = find(a);
    b = find(b);
    if(a == b)
        return 0;
    par[a] = b;
    return 1;
}
int construct_roads(vector<int> x, vector<int> y) {
    if (x.size() == 1) {
	    build({}, {}, {}, {});
        return 1;
    }
    int n = x.size();
    map<pair<int,int>,int> mp;
    for(int i = 0;i<n;i++){
        par[i] = i;
        mp[{x[i],y[i]}] = i;
    }
    vector<int> u, v, a, b;
    vector<pair<int,int>> ord;
    for(int i = 0;i<n;i++){
        for(auto dx:{-2,0,2}){
            for(auto dy:{0}){
                if(abs(dx) + abs(dy) != 2)continue;
                if(!mp.count({x[i]+dx,y[i]+dy}))continue;
                if(merge(i,mp[{x[i]+dx,y[i]+dy}])){
                    ord.push_back({i,mp[{x[i]+dx,y[i]+dy}]});
                }
            }
        }
    }
    for(int i = 0;i<n;i++){
        for(auto dx:{-2,0,2}){
            for(auto dy:{-2,0,2}){
                if(abs(dx) + abs(dy) != 2)continue;
                if(x[i] == 4)continue;
                if(!mp.count({x[i]+dx,y[i]+dy}))continue;
                if(merge(i,mp[{x[i]+dx,y[i]+dy}])){
                    ord.push_back({i,mp[{x[i]+dx,y[i]+dy}]});
                }
            }
        }
    }
    for(int i = 0;i<n;i++){
        for(auto dx:{-2,0,2}){
            for(auto dy:{-2,0,2}){
                if(abs(dx) + abs(dy) != 2)continue;
                if(!mp.count({x[i]+dx,y[i]+dy}))continue;
                if(merge(i,mp[{x[i]+dx,y[i]+dy}])){
                    ord.push_back({i,mp[{x[i]+dx,y[i]+dy}]});
                }
            }
        }
    }
    sort(ord.begin(),ord.end(),[&](pair<int,int> c,pair<int,int> d){
        if(max(x[c.first],x[c.second]) != max(x[d.first],x[d.second])){
            return max(x[c.first],x[c.second]) < max(x[d.first],x[d.second]);
        }
        return max(y[c.first],y[c.second]) < max(y[d.first],y[d.second]);
    });
    for(auto c:ord){
        u.push_back(c.first);
        v.push_back(c.second);
    }
    if(u.size() != n-1)
        return 0;
    a.assign(n-1,-1);
    b.assign(n-1,-1);
    map<pair<int,int>,int> used;
    map<int,int> cnt;
    map<pair<int,int>,vector<int>> mpp;
    set<pair<int,int>> s;
    for(int i = 0;i<n-1;i++){
        for(auto dx:{-1,1}){
            for(auto dy:{-1,1}){   
                if(abs(x[u[i]]+dx - x[v[i]]) != 1 || abs(y[u[i]]+dy - y[v[i]]) != 1)continue;
                cnt[i]++;
                mpp[{x[u[i]]+dx,y[u[i]]+dy}].push_back(i);
            }
        }
        s.insert({cnt[i],i});
    }
    while(s.size()){
        auto tp = *s.begin();
        if(tp.first == 0){
            assert(0);
        }
        s.erase(tp);
        int i = tp.second;
        bool ok = 0;
        for(auto dx:{-1,1}){
            for(auto dy:{-1,1}){
                if(ok)continue;
                if(used.count({x[u[i]]+dx,y[u[i]]+dy}))continue;     
                if(abs(x[u[i]]+dx - x[v[i]]) != 1 || abs(y[u[i]]+dy - y[v[i]]) != 1)continue;
                used[{x[u[i]]+dx,y[u[i]]+dy}] = 1;
                a[i] = x[u[i]] + dx;
                b[i] = y[u[i]] + dy;
                for(auto z:mpp[{x[u[i]]+dx,y[u[i]]+dy}]){
                    if(a[z] != -1)continue;
                    s.erase({cnt[z],z});
                    cnt[z]--;
                    s.insert({cnt[z],z});
                }
                ok = 1;
            }
        }
    }
    build(u, v, a, b);
    return 1;
}

Compilation message

parks.cpp: In function 'int construct_roads(std::vector<int>, std::vector<int>)':
parks.cpp:75:17: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
   75 |     if(u.size() != n-1)
      |        ~~~~~~~~~^~~~~~
# Verdict Execution time Memory Grader output
1 Correct 0 ms 212 KB Output is correct
2 Correct 0 ms 212 KB Output is correct
3 Correct 0 ms 212 KB Output is correct
4 Correct 0 ms 224 KB Output is correct
5 Correct 1 ms 212 KB Output is correct
6 Correct 0 ms 212 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 521 ms 52204 KB Output is correct
10 Correct 37 ms 5744 KB Output is correct
11 Correct 253 ms 28844 KB Output is correct
12 Correct 62 ms 8440 KB Output is correct
13 Correct 83 ms 5320 KB Output is correct
14 Correct 2 ms 340 KB Output is correct
15 Correct 3 ms 468 KB Output is correct
16 Correct 608 ms 52052 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 212 KB Output is correct
2 Correct 0 ms 212 KB Output is correct
3 Correct 0 ms 212 KB Output is correct
4 Correct 0 ms 224 KB Output is correct
5 Correct 1 ms 212 KB Output is correct
6 Correct 0 ms 212 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 521 ms 52204 KB Output is correct
10 Correct 37 ms 5744 KB Output is correct
11 Correct 253 ms 28844 KB Output is correct
12 Correct 62 ms 8440 KB Output is correct
13 Correct 83 ms 5320 KB Output is correct
14 Correct 2 ms 340 KB Output is correct
15 Correct 3 ms 468 KB Output is correct
16 Correct 608 ms 52052 KB Output is correct
17 Correct 0 ms 212 KB Output is correct
18 Correct 1 ms 212 KB Output is correct
19 Correct 0 ms 212 KB Output is correct
20 Correct 0 ms 212 KB Output is correct
21 Correct 0 ms 212 KB Output is correct
22 Correct 0 ms 212 KB Output is correct
23 Correct 1643 ms 81972 KB Output is correct
24 Correct 1 ms 212 KB Output is correct
25 Correct 4 ms 736 KB Output is correct
26 Correct 5 ms 616 KB Output is correct
27 Correct 8 ms 596 KB Output is correct
28 Correct 497 ms 33044 KB Output is correct
29 Correct 817 ms 49296 KB Output is correct
30 Correct 1191 ms 65596 KB Output is correct
31 Correct 1423 ms 82044 KB Output is correct
32 Correct 1 ms 212 KB Output is correct
33 Correct 0 ms 212 KB Output is correct
34 Correct 0 ms 212 KB Output is correct
35 Correct 0 ms 212 KB Output is correct
36 Correct 0 ms 212 KB Output is correct
37 Correct 0 ms 212 KB Output is correct
38 Correct 0 ms 212 KB Output is correct
39 Correct 0 ms 212 KB Output is correct
40 Correct 0 ms 212 KB Output is correct
41 Correct 1 ms 212 KB Output is correct
42 Correct 0 ms 212 KB Output is correct
43 Correct 4 ms 468 KB Output is correct
44 Correct 6 ms 596 KB Output is correct
45 Correct 562 ms 45312 KB Output is correct
46 Correct 908 ms 65548 KB Output is correct
47 Correct 922 ms 65580 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 212 KB Output is correct
2 Correct 0 ms 212 KB Output is correct
3 Correct 0 ms 212 KB Output is correct
4 Correct 0 ms 224 KB Output is correct
5 Correct 1 ms 212 KB Output is correct
6 Correct 0 ms 212 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 521 ms 52204 KB Output is correct
10 Correct 37 ms 5744 KB Output is correct
11 Correct 253 ms 28844 KB Output is correct
12 Correct 62 ms 8440 KB Output is correct
13 Correct 83 ms 5320 KB Output is correct
14 Correct 2 ms 340 KB Output is correct
15 Correct 3 ms 468 KB Output is correct
16 Correct 608 ms 52052 KB Output is correct
17 Correct 0 ms 212 KB Output is correct
18 Correct 1 ms 212 KB Output is correct
19 Correct 0 ms 212 KB Output is correct
20 Correct 0 ms 212 KB Output is correct
21 Correct 0 ms 212 KB Output is correct
22 Correct 0 ms 212 KB Output is correct
23 Correct 1643 ms 81972 KB Output is correct
24 Correct 1 ms 212 KB Output is correct
25 Correct 4 ms 736 KB Output is correct
26 Correct 5 ms 616 KB Output is correct
27 Correct 8 ms 596 KB Output is correct
28 Correct 497 ms 33044 KB Output is correct
29 Correct 817 ms 49296 KB Output is correct
30 Correct 1191 ms 65596 KB Output is correct
31 Correct 1423 ms 82044 KB Output is correct
32 Correct 1 ms 212 KB Output is correct
33 Correct 0 ms 212 KB Output is correct
34 Correct 0 ms 212 KB Output is correct
35 Correct 0 ms 212 KB Output is correct
36 Correct 0 ms 212 KB Output is correct
37 Correct 0 ms 212 KB Output is correct
38 Correct 0 ms 212 KB Output is correct
39 Correct 0 ms 212 KB Output is correct
40 Correct 0 ms 212 KB Output is correct
41 Correct 1 ms 212 KB Output is correct
42 Correct 0 ms 212 KB Output is correct
43 Correct 4 ms 468 KB Output is correct
44 Correct 6 ms 596 KB Output is correct
45 Correct 562 ms 45312 KB Output is correct
46 Correct 908 ms 65548 KB Output is correct
47 Correct 922 ms 65580 KB Output is correct
48 Correct 1 ms 212 KB Output is correct
49 Correct 0 ms 212 KB Output is correct
50 Correct 0 ms 212 KB Output is correct
51 Correct 1 ms 212 KB Output is correct
52 Correct 0 ms 212 KB Output is correct
53 Correct 1 ms 212 KB Output is correct
54 Correct 0 ms 212 KB Output is correct
55 Correct 1557 ms 81892 KB Output is correct
56 Correct 1 ms 212 KB Output is correct
57 Correct 7 ms 952 KB Output is correct
58 Correct 24 ms 2860 KB Output is correct
59 Correct 25 ms 1348 KB Output is correct
60 Correct 625 ms 41940 KB Output is correct
61 Correct 888 ms 56440 KB Output is correct
62 Correct 1160 ms 69172 KB Output is correct
63 Correct 1507 ms 83712 KB Output is correct
64 Correct 1 ms 212 KB Output is correct
65 Correct 1 ms 212 KB Output is correct
66 Correct 0 ms 212 KB Output is correct
67 Correct 1225 ms 105620 KB Output is correct
68 Correct 1234 ms 105588 KB Output is correct
69 Correct 1276 ms 105040 KB Output is correct
70 Correct 8 ms 724 KB Output is correct
71 Correct 19 ms 1108 KB Output is correct
72 Correct 609 ms 45480 KB Output is correct
73 Correct 1002 ms 68264 KB Output is correct
74 Correct 1466 ms 90936 KB Output is correct
75 Correct 1474 ms 92412 KB Output is correct
76 Correct 1234 ms 105696 KB Output is correct
77 Correct 9 ms 860 KB Output is correct
78 Correct 19 ms 1308 KB Output is correct
79 Correct 573 ms 45348 KB Output is correct
80 Correct 967 ms 67996 KB Output is correct
81 Correct 1423 ms 90660 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 212 KB Output is correct
2 Correct 0 ms 212 KB Output is correct
3 Correct 0 ms 212 KB Output is correct
4 Correct 0 ms 224 KB Output is correct
5 Correct 1 ms 212 KB Output is correct
6 Correct 0 ms 212 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 521 ms 52204 KB Output is correct
10 Correct 37 ms 5744 KB Output is correct
11 Correct 253 ms 28844 KB Output is correct
12 Correct 62 ms 8440 KB Output is correct
13 Correct 83 ms 5320 KB Output is correct
14 Correct 2 ms 340 KB Output is correct
15 Correct 3 ms 468 KB Output is correct
16 Correct 608 ms 52052 KB Output is correct
17 Correct 0 ms 212 KB Output is correct
18 Correct 0 ms 212 KB Output is correct
19 Correct 1 ms 212 KB Output is correct
20 Correct 1476 ms 82872 KB Output is correct
21 Correct 1539 ms 82680 KB Output is correct
22 Correct 1885 ms 82756 KB Output is correct
23 Correct 1152 ms 88892 KB Output is correct
24 Correct 626 ms 16744 KB Output is correct
25 Correct 1163 ms 21188 KB Output is correct
26 Correct 872 ms 21124 KB Output is correct
27 Correct 1298 ms 104024 KB Output is correct
28 Correct 1274 ms 103892 KB Output is correct
29 Correct 1712 ms 103856 KB Output is correct
30 Correct 1735 ms 103836 KB Output is correct
31 Correct 0 ms 212 KB Output is correct
32 Correct 63 ms 6672 KB Output is correct
33 Correct 206 ms 8504 KB Output is correct
34 Correct 1274 ms 83196 KB Output is correct
35 Correct 27 ms 1356 KB Output is correct
36 Correct 175 ms 5448 KB Output is correct
37 Correct 418 ms 10448 KB Output is correct
38 Correct 469 ms 35176 KB Output is correct
39 Correct 727 ms 47892 KB Output is correct
40 Correct 989 ms 61116 KB Output is correct
41 Correct 1295 ms 74116 KB Output is correct
42 Correct 1614 ms 87216 KB Output is correct
43 Correct 0 ms 212 KB Output is correct
44 Correct 1 ms 212 KB Output is correct
45 Correct 0 ms 212 KB Output is correct
46 Correct 0 ms 212 KB Output is correct
47 Correct 1 ms 212 KB Output is correct
48 Correct 0 ms 212 KB Output is correct
49 Correct 0 ms 212 KB Output is correct
50 Correct 0 ms 212 KB Output is correct
51 Correct 0 ms 212 KB Output is correct
52 Correct 0 ms 212 KB Output is correct
53 Correct 0 ms 212 KB Output is correct
54 Correct 3 ms 468 KB Output is correct
55 Correct 5 ms 596 KB Output is correct
56 Correct 558 ms 45464 KB Output is correct
57 Correct 834 ms 65592 KB Output is correct
58 Correct 847 ms 65684 KB Output is correct
59 Correct 0 ms 212 KB Output is correct
60 Correct 0 ms 212 KB Output is correct
61 Correct 0 ms 212 KB Output is correct
62 Correct 1193 ms 104164 KB Output is correct
63 Correct 1191 ms 104064 KB Output is correct
64 Correct 1146 ms 103468 KB Output is correct
65 Correct 8 ms 596 KB Output is correct
66 Correct 18 ms 1108 KB Output is correct
67 Correct 543 ms 44800 KB Output is correct
68 Correct 928 ms 67148 KB Output is correct
69 Correct 1351 ms 89372 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 212 KB Output is correct
2 Correct 0 ms 212 KB Output is correct
3 Correct 0 ms 212 KB Output is correct
4 Correct 0 ms 224 KB Output is correct
5 Correct 1 ms 212 KB Output is correct
6 Correct 0 ms 212 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 521 ms 52204 KB Output is correct
10 Correct 37 ms 5744 KB Output is correct
11 Correct 253 ms 28844 KB Output is correct
12 Correct 62 ms 8440 KB Output is correct
13 Correct 83 ms 5320 KB Output is correct
14 Correct 2 ms 340 KB Output is correct
15 Correct 3 ms 468 KB Output is correct
16 Correct 608 ms 52052 KB Output is correct
17 Correct 1358 ms 104532 KB Output is correct
18 Correct 1279 ms 104676 KB Output is correct
19 Correct 1556 ms 82664 KB Output is correct
20 Correct 1583 ms 87536 KB Output is correct
21 Correct 1320 ms 84660 KB Output is correct
22 Correct 0 ms 212 KB Output is correct
23 Correct 166 ms 14280 KB Output is correct
24 Correct 60 ms 2388 KB Output is correct
25 Correct 279 ms 7748 KB Output is correct
26 Correct 566 ms 12436 KB Output is correct
27 Correct 645 ms 44732 KB Output is correct
28 Correct 861 ms 55920 KB Output is correct
29 Correct 1114 ms 67040 KB Output is correct
30 Correct 1373 ms 77940 KB Output is correct
31 Correct 1658 ms 89284 KB Output is correct
32 Correct 1375 ms 90892 KB Output is correct
33 Correct 1221 ms 104180 KB Output is correct
34 Correct 9 ms 724 KB Output is correct
35 Correct 18 ms 1236 KB Output is correct
36 Correct 551 ms 44796 KB Output is correct
37 Correct 936 ms 67044 KB Output is correct
38 Correct 1374 ms 89028 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 212 KB Output is correct
2 Correct 0 ms 212 KB Output is correct
3 Correct 0 ms 212 KB Output is correct
4 Correct 0 ms 224 KB Output is correct
5 Correct 1 ms 212 KB Output is correct
6 Correct 0 ms 212 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 521 ms 52204 KB Output is correct
10 Correct 37 ms 5744 KB Output is correct
11 Correct 253 ms 28844 KB Output is correct
12 Correct 62 ms 8440 KB Output is correct
13 Correct 83 ms 5320 KB Output is correct
14 Correct 2 ms 340 KB Output is correct
15 Correct 3 ms 468 KB Output is correct
16 Correct 608 ms 52052 KB Output is correct
17 Correct 0 ms 212 KB Output is correct
18 Correct 1 ms 212 KB Output is correct
19 Correct 0 ms 212 KB Output is correct
20 Correct 0 ms 212 KB Output is correct
21 Correct 0 ms 212 KB Output is correct
22 Correct 0 ms 212 KB Output is correct
23 Correct 1643 ms 81972 KB Output is correct
24 Correct 1 ms 212 KB Output is correct
25 Correct 4 ms 736 KB Output is correct
26 Correct 5 ms 616 KB Output is correct
27 Correct 8 ms 596 KB Output is correct
28 Correct 497 ms 33044 KB Output is correct
29 Correct 817 ms 49296 KB Output is correct
30 Correct 1191 ms 65596 KB Output is correct
31 Correct 1423 ms 82044 KB Output is correct
32 Correct 1 ms 212 KB Output is correct
33 Correct 0 ms 212 KB Output is correct
34 Correct 0 ms 212 KB Output is correct
35 Correct 0 ms 212 KB Output is correct
36 Correct 0 ms 212 KB Output is correct
37 Correct 0 ms 212 KB Output is correct
38 Correct 0 ms 212 KB Output is correct
39 Correct 0 ms 212 KB Output is correct
40 Correct 0 ms 212 KB Output is correct
41 Correct 1 ms 212 KB Output is correct
42 Correct 0 ms 212 KB Output is correct
43 Correct 4 ms 468 KB Output is correct
44 Correct 6 ms 596 KB Output is correct
45 Correct 562 ms 45312 KB Output is correct
46 Correct 908 ms 65548 KB Output is correct
47 Correct 922 ms 65580 KB Output is correct
48 Correct 1 ms 212 KB Output is correct
49 Correct 0 ms 212 KB Output is correct
50 Correct 0 ms 212 KB Output is correct
51 Correct 1 ms 212 KB Output is correct
52 Correct 0 ms 212 KB Output is correct
53 Correct 1 ms 212 KB Output is correct
54 Correct 0 ms 212 KB Output is correct
55 Correct 1557 ms 81892 KB Output is correct
56 Correct 1 ms 212 KB Output is correct
57 Correct 7 ms 952 KB Output is correct
58 Correct 24 ms 2860 KB Output is correct
59 Correct 25 ms 1348 KB Output is correct
60 Correct 625 ms 41940 KB Output is correct
61 Correct 888 ms 56440 KB Output is correct
62 Correct 1160 ms 69172 KB Output is correct
63 Correct 1507 ms 83712 KB Output is correct
64 Correct 1 ms 212 KB Output is correct
65 Correct 1 ms 212 KB Output is correct
66 Correct 0 ms 212 KB Output is correct
67 Correct 1225 ms 105620 KB Output is correct
68 Correct 1234 ms 105588 KB Output is correct
69 Correct 1276 ms 105040 KB Output is correct
70 Correct 8 ms 724 KB Output is correct
71 Correct 19 ms 1108 KB Output is correct
72 Correct 609 ms 45480 KB Output is correct
73 Correct 1002 ms 68264 KB Output is correct
74 Correct 1466 ms 90936 KB Output is correct
75 Correct 1474 ms 92412 KB Output is correct
76 Correct 1234 ms 105696 KB Output is correct
77 Correct 9 ms 860 KB Output is correct
78 Correct 19 ms 1308 KB Output is correct
79 Correct 573 ms 45348 KB Output is correct
80 Correct 967 ms 67996 KB Output is correct
81 Correct 1423 ms 90660 KB Output is correct
82 Correct 0 ms 212 KB Output is correct
83 Correct 0 ms 212 KB Output is correct
84 Correct 1 ms 212 KB Output is correct
85 Correct 1476 ms 82872 KB Output is correct
86 Correct 1539 ms 82680 KB Output is correct
87 Correct 1885 ms 82756 KB Output is correct
88 Correct 1152 ms 88892 KB Output is correct
89 Correct 626 ms 16744 KB Output is correct
90 Correct 1163 ms 21188 KB Output is correct
91 Correct 872 ms 21124 KB Output is correct
92 Correct 1298 ms 104024 KB Output is correct
93 Correct 1274 ms 103892 KB Output is correct
94 Correct 1712 ms 103856 KB Output is correct
95 Correct 1735 ms 103836 KB Output is correct
96 Correct 0 ms 212 KB Output is correct
97 Correct 63 ms 6672 KB Output is correct
98 Correct 206 ms 8504 KB Output is correct
99 Correct 1274 ms 83196 KB Output is correct
100 Correct 27 ms 1356 KB Output is correct
101 Correct 175 ms 5448 KB Output is correct
102 Correct 418 ms 10448 KB Output is correct
103 Correct 469 ms 35176 KB Output is correct
104 Correct 727 ms 47892 KB Output is correct
105 Correct 989 ms 61116 KB Output is correct
106 Correct 1295 ms 74116 KB Output is correct
107 Correct 1614 ms 87216 KB Output is correct
108 Correct 0 ms 212 KB Output is correct
109 Correct 1 ms 212 KB Output is correct
110 Correct 0 ms 212 KB Output is correct
111 Correct 0 ms 212 KB Output is correct
112 Correct 1 ms 212 KB Output is correct
113 Correct 0 ms 212 KB Output is correct
114 Correct 0 ms 212 KB Output is correct
115 Correct 0 ms 212 KB Output is correct
116 Correct 0 ms 212 KB Output is correct
117 Correct 0 ms 212 KB Output is correct
118 Correct 0 ms 212 KB Output is correct
119 Correct 3 ms 468 KB Output is correct
120 Correct 5 ms 596 KB Output is correct
121 Correct 558 ms 45464 KB Output is correct
122 Correct 834 ms 65592 KB Output is correct
123 Correct 847 ms 65684 KB Output is correct
124 Correct 0 ms 212 KB Output is correct
125 Correct 0 ms 212 KB Output is correct
126 Correct 0 ms 212 KB Output is correct
127 Correct 1193 ms 104164 KB Output is correct
128 Correct 1191 ms 104064 KB Output is correct
129 Correct 1146 ms 103468 KB Output is correct
130 Correct 8 ms 596 KB Output is correct
131 Correct 18 ms 1108 KB Output is correct
132 Correct 543 ms 44800 KB Output is correct
133 Correct 928 ms 67148 KB Output is correct
134 Correct 1351 ms 89372 KB Output is correct
135 Correct 1358 ms 104532 KB Output is correct
136 Correct 1279 ms 104676 KB Output is correct
137 Correct 1556 ms 82664 KB Output is correct
138 Correct 1583 ms 87536 KB Output is correct
139 Correct 1320 ms 84660 KB Output is correct
140 Correct 0 ms 212 KB Output is correct
141 Correct 166 ms 14280 KB Output is correct
142 Correct 60 ms 2388 KB Output is correct
143 Correct 279 ms 7748 KB Output is correct
144 Correct 566 ms 12436 KB Output is correct
145 Correct 645 ms 44732 KB Output is correct
146 Correct 861 ms 55920 KB Output is correct
147 Correct 1114 ms 67040 KB Output is correct
148 Correct 1373 ms 77940 KB Output is correct
149 Correct 1658 ms 89284 KB Output is correct
150 Correct 1375 ms 90892 KB Output is correct
151 Correct 1221 ms 104180 KB Output is correct
152 Correct 9 ms 724 KB Output is correct
153 Correct 18 ms 1236 KB Output is correct
154 Correct 551 ms 44796 KB Output is correct
155 Correct 936 ms 67044 KB Output is correct
156 Correct 1374 ms 89028 KB Output is correct
157 Correct 1 ms 212 KB Output is correct
158 Correct 1 ms 212 KB Output is correct
159 Correct 1 ms 212 KB Output is correct
160 Correct 0 ms 308 KB Output is correct
161 Runtime error 1481 ms 128156 KB Execution killed with signal 6
162 Halted 0 ms 0 KB -