Submission #770866

# Submission time Handle Problem Language Result Execution time Memory
770866 2023-07-02T05:13:40 Z marvinthang Fountain Parks (IOI21_parks) C++17
100 / 100
359 ms 42600 KB
/*************************************
*    author: marvinthang             *
*    created: 02.07.2023 11:47:17    *
*************************************/

#include "parks.h"
#include <bits/stdc++.h>

using namespace std;

#define                  fi  first
#define                  se  second
#define                left  ___left
#define               right  ___right
#define                TIME  (1.0 * clock() / CLOCKS_PER_SEC)
#define             MASK(i)  (1LL << (i))
#define           BIT(x, i)  ((x) >> (i) & 1)
#define  __builtin_popcount  __builtin_popcountll
#define              ALL(v)  (v).begin(), (v).end()
#define           REP(i, n)  for (int i = 0, _n = (n); i < _n; ++i)
#define          REPD(i, n)  for (int i = (n); i--; )
#define        FOR(i, a, b)  for (int i = (a), _b = (b); i < _b; ++i) 
#define       FORD(i, b, a)  for (int i = (b), _a = (a); --i >= _a; ) 
#define       FORE(i, a, b)  for (int i = (a), _b = (b); i <= _b; ++i) 
#define      FORDE(i, b, a)  for (int i = (b), _a = (a); i >= _a; --i) 
#define        scan_op(...)  istream & operator >> (istream &in, __VA_ARGS__ &u)
#define       print_op(...)  ostream & operator << (ostream &out, const __VA_ARGS__ &u)
#ifdef LOCAL
    #include "debug.h"
#else
    #define file(name) if (fopen(name".inp", "r")) { freopen(name".inp", "r", stdin); freopen(name".out", "w", stdout); }
    #define DB(...) 23
    #define db(...) 23
    #define debug(...) 23
#endif

template <class U, class V> scan_op(pair <U, V>)  { return in >> u.first >> u.second; }
template <class T> scan_op(vector <T>)  { for (size_t i = 0; i < u.size(); ++i) in >> u[i]; return in; }
template <class U, class V> print_op(pair <U, V>)  { return out << '(' << u.first << ", " << u.second << ')'; }
template <size_t i, class T> ostream & print_tuple_utils(ostream &out, const T &tup) { if constexpr(i == tuple_size<T>::value) return out << ")";  else return print_tuple_utils<i + 1, T>(out << (i ? ", " : "(") << get<i>(tup), tup); }
template <class ...U> print_op(tuple<U...>) { return print_tuple_utils<0, tuple<U...>>(out, u); }
template <class Con, class = decltype(begin(declval<Con>()))> typename enable_if <!is_same<Con, string>::value, ostream&>::type operator << (ostream &out, const Con &con) { out << '{'; for (__typeof(con.begin()) it = con.begin(); it != con.end(); ++it) out << (it == con.begin() ? "" : ", ") << *it; return out << '}'; }

// end of template

struct DisjointSet {
    
    int n, *lab = nullptr;

    DisjointSet(int _n = 0) {
        resize(_n);
    }

    void reset(void) {
        memset(lab, -1, (n + 1) * sizeof(int));
    }

    void resize(int _n) {
         if (lab != nullptr) delete[] lab;
         n = _n;
         lab = new int[n + 1];
         reset();
    }

    int find(int u) {
        assert(u <= n);
        return lab[u] < 0 ? u : lab[u] = find(lab[u]);
    }

    bool connected(int u, int v) { return find(u) == find(v); }
    bool isRoot(int u) { return lab[u] < 0; }
    int size(int u) { return -lab[find(u)]; }

    bool join(int u, int v) {
        if ((u = find(u)) == (v = find(v))) return false;
        if (lab[u] > lab[v]) swap(u, v);
        lab[u] += lab[v];
        lab[v] = u;
        return true;
    }

};

using DSU = DisjointSet;

int construct_roads(vector <int> x, vector <int> y) {
    int n = x.size();
    map <pair <int, int>, int> id;
    vector <pair <int, int>> p;
    REP(i, n) {
        p.emplace_back(x[i], y[i]);
        id[p.back()] = i;
    }
    sort(ALL(p));
    vector <int> U, V, A, B;
    set <pair <int, int>> used;
    DSU dsu(n);
    auto addEdge = [&] (int u, int v, int a, int b) {
        if (!~u || !~v || !used.insert(make_pair(a, b)).se || !dsu.join(u, v)) return false;
        U.push_back(u);
        V.push_back(v);
        A.push_back(a);
        B.push_back(b);
        return true;
    };
    for (auto [x, y]: p) {
        int a = id[make_pair(x, y)];
        int b = id.count(make_pair(x - 2, y)) ? id[make_pair(x - 2, y)] : -1;
        int c = id.count(make_pair(x, y - 2)) ? id[make_pair(x, y - 2)] : -1;
        if (x + y & 3) {
            addEdge(a, b, x - 1, y - 1);
            addEdge(a, c, x + 1, y - 1);
        } else {
            addEdge(a, c, x - 1, y - 1);
            addEdge(a, b, x - 1, y + 1);
        }
    }
    if (U.size() != n - 1) return 0;
    build(U, V, A, B);
    return 1;
}

Compilation message

parks.cpp: In function 'int construct_roads(std::vector<int>, std::vector<int>)':
parks.cpp:110:15: warning: suggest parentheses around '+' in operand of '&' [-Wparentheses]
  110 |         if (x + y & 3) {
      |             ~~^~~
parks.cpp:118:18: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
  118 |     if (U.size() != n - 1) return 0;
      |         ~~~~~~~~~^~~~~~~~
# Verdict Execution time Memory Grader output
1 Correct 1 ms 212 KB Output is correct
2 Correct 1 ms 212 KB Output is correct
3 Correct 0 ms 300 KB Output is correct
4 Correct 1 ms 296 KB Output is correct
5 Correct 1 ms 300 KB Output is correct
6 Correct 0 ms 300 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 120 ms 19508 KB Output is correct
10 Correct 10 ms 2308 KB Output is correct
11 Correct 58 ms 10700 KB Output is correct
12 Correct 14 ms 3352 KB Output is correct
13 Correct 35 ms 7440 KB Output is correct
14 Correct 1 ms 468 KB Output is correct
15 Correct 2 ms 596 KB Output is correct
16 Correct 121 ms 19548 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 212 KB Output is correct
2 Correct 1 ms 212 KB Output is correct
3 Correct 0 ms 300 KB Output is correct
4 Correct 1 ms 296 KB Output is correct
5 Correct 1 ms 300 KB Output is correct
6 Correct 0 ms 300 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 120 ms 19508 KB Output is correct
10 Correct 10 ms 2308 KB Output is correct
11 Correct 58 ms 10700 KB Output is correct
12 Correct 14 ms 3352 KB Output is correct
13 Correct 35 ms 7440 KB Output is correct
14 Correct 1 ms 468 KB Output is correct
15 Correct 2 ms 596 KB Output is correct
16 Correct 121 ms 19548 KB Output is correct
17 Correct 1 ms 212 KB Output is correct
18 Correct 1 ms 212 KB Output is correct
19 Correct 1 ms 300 KB Output is correct
20 Correct 0 ms 212 KB Output is correct
21 Correct 1 ms 212 KB Output is correct
22 Correct 0 ms 212 KB Output is correct
23 Correct 347 ms 40104 KB Output is correct
24 Correct 1 ms 212 KB Output is correct
25 Correct 2 ms 596 KB Output is correct
26 Correct 3 ms 724 KB Output is correct
27 Correct 4 ms 872 KB Output is correct
28 Correct 99 ms 16156 KB Output is correct
29 Correct 178 ms 24028 KB Output is correct
30 Correct 240 ms 32540 KB Output is correct
31 Correct 303 ms 40160 KB Output is correct
32 Correct 1 ms 300 KB Output is correct
33 Correct 1 ms 300 KB Output is correct
34 Correct 1 ms 212 KB Output is correct
35 Correct 0 ms 212 KB Output is correct
36 Correct 0 ms 296 KB Output is correct
37 Correct 0 ms 304 KB Output is correct
38 Correct 0 ms 296 KB Output is correct
39 Correct 0 ms 212 KB Output is correct
40 Correct 1 ms 212 KB Output is correct
41 Correct 1 ms 212 KB Output is correct
42 Correct 1 ms 212 KB Output is correct
43 Correct 3 ms 596 KB Output is correct
44 Correct 3 ms 728 KB Output is correct
45 Correct 121 ms 20172 KB Output is correct
46 Correct 191 ms 29804 KB Output is correct
47 Correct 200 ms 29720 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 212 KB Output is correct
2 Correct 1 ms 212 KB Output is correct
3 Correct 0 ms 300 KB Output is correct
4 Correct 1 ms 296 KB Output is correct
5 Correct 1 ms 300 KB Output is correct
6 Correct 0 ms 300 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 120 ms 19508 KB Output is correct
10 Correct 10 ms 2308 KB Output is correct
11 Correct 58 ms 10700 KB Output is correct
12 Correct 14 ms 3352 KB Output is correct
13 Correct 35 ms 7440 KB Output is correct
14 Correct 1 ms 468 KB Output is correct
15 Correct 2 ms 596 KB Output is correct
16 Correct 121 ms 19548 KB Output is correct
17 Correct 1 ms 212 KB Output is correct
18 Correct 1 ms 212 KB Output is correct
19 Correct 1 ms 300 KB Output is correct
20 Correct 0 ms 212 KB Output is correct
21 Correct 1 ms 212 KB Output is correct
22 Correct 0 ms 212 KB Output is correct
23 Correct 347 ms 40104 KB Output is correct
24 Correct 1 ms 212 KB Output is correct
25 Correct 2 ms 596 KB Output is correct
26 Correct 3 ms 724 KB Output is correct
27 Correct 4 ms 872 KB Output is correct
28 Correct 99 ms 16156 KB Output is correct
29 Correct 178 ms 24028 KB Output is correct
30 Correct 240 ms 32540 KB Output is correct
31 Correct 303 ms 40160 KB Output is correct
32 Correct 1 ms 300 KB Output is correct
33 Correct 1 ms 300 KB Output is correct
34 Correct 1 ms 212 KB Output is correct
35 Correct 0 ms 212 KB Output is correct
36 Correct 0 ms 296 KB Output is correct
37 Correct 0 ms 304 KB Output is correct
38 Correct 0 ms 296 KB Output is correct
39 Correct 0 ms 212 KB Output is correct
40 Correct 1 ms 212 KB Output is correct
41 Correct 1 ms 212 KB Output is correct
42 Correct 1 ms 212 KB Output is correct
43 Correct 3 ms 596 KB Output is correct
44 Correct 3 ms 728 KB Output is correct
45 Correct 121 ms 20172 KB Output is correct
46 Correct 191 ms 29804 KB Output is correct
47 Correct 200 ms 29720 KB Output is correct
48 Correct 1 ms 212 KB Output is correct
49 Correct 0 ms 296 KB Output is correct
50 Correct 0 ms 212 KB Output is correct
51 Correct 0 ms 212 KB Output is correct
52 Correct 1 ms 212 KB Output is correct
53 Correct 0 ms 300 KB Output is correct
54 Correct 0 ms 212 KB Output is correct
55 Correct 319 ms 40044 KB Output is correct
56 Correct 1 ms 212 KB Output is correct
57 Correct 2 ms 672 KB Output is correct
58 Correct 7 ms 1492 KB Output is correct
59 Correct 8 ms 1900 KB Output is correct
60 Correct 130 ms 19964 KB Output is correct
61 Correct 190 ms 28048 KB Output is correct
62 Correct 272 ms 33384 KB Output is correct
63 Correct 318 ms 40292 KB Output is correct
64 Correct 1 ms 212 KB Output is correct
65 Correct 0 ms 212 KB Output is correct
66 Correct 0 ms 212 KB Output is correct
67 Correct 273 ms 40104 KB Output is correct
68 Correct 271 ms 40056 KB Output is correct
69 Correct 289 ms 39904 KB Output is correct
70 Correct 3 ms 852 KB Output is correct
71 Correct 7 ms 1492 KB Output is correct
72 Correct 132 ms 20008 KB Output is correct
73 Correct 210 ms 30600 KB Output is correct
74 Correct 321 ms 40248 KB Output is correct
75 Correct 285 ms 41964 KB Output is correct
76 Correct 268 ms 40152 KB Output is correct
77 Correct 4 ms 1108 KB Output is correct
78 Correct 8 ms 1748 KB Output is correct
79 Correct 129 ms 20396 KB Output is correct
80 Correct 204 ms 31144 KB Output is correct
81 Correct 306 ms 41208 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 212 KB Output is correct
2 Correct 1 ms 212 KB Output is correct
3 Correct 0 ms 300 KB Output is correct
4 Correct 1 ms 296 KB Output is correct
5 Correct 1 ms 300 KB Output is correct
6 Correct 0 ms 300 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 120 ms 19508 KB Output is correct
10 Correct 10 ms 2308 KB Output is correct
11 Correct 58 ms 10700 KB Output is correct
12 Correct 14 ms 3352 KB Output is correct
13 Correct 35 ms 7440 KB Output is correct
14 Correct 1 ms 468 KB Output is correct
15 Correct 2 ms 596 KB Output is correct
16 Correct 121 ms 19548 KB Output is correct
17 Correct 0 ms 212 KB Output is correct
18 Correct 0 ms 212 KB Output is correct
19 Correct 0 ms 212 KB Output is correct
20 Correct 280 ms 39836 KB Output is correct
21 Correct 287 ms 39496 KB Output is correct
22 Correct 297 ms 39620 KB Output is correct
23 Correct 239 ms 33716 KB Output is correct
24 Correct 151 ms 19936 KB Output is correct
25 Correct 241 ms 32664 KB Output is correct
26 Correct 213 ms 32576 KB Output is correct
27 Correct 261 ms 38732 KB Output is correct
28 Correct 260 ms 38824 KB Output is correct
29 Correct 296 ms 38756 KB Output is correct
30 Correct 288 ms 38724 KB Output is correct
31 Correct 1 ms 212 KB Output is correct
32 Correct 16 ms 3300 KB Output is correct
33 Correct 69 ms 10532 KB Output is correct
34 Correct 278 ms 39752 KB Output is correct
35 Correct 9 ms 2004 KB Output is correct
36 Correct 51 ms 8588 KB Output is correct
37 Correct 100 ms 16704 KB Output is correct
38 Correct 111 ms 16372 KB Output is correct
39 Correct 152 ms 21992 KB Output is correct
40 Correct 194 ms 28848 KB Output is correct
41 Correct 249 ms 34184 KB Output is correct
42 Correct 281 ms 39784 KB Output is correct
43 Correct 0 ms 212 KB Output is correct
44 Correct 0 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 0 ms 212 KB Output is correct
48 Correct 0 ms 304 KB Output is correct
49 Correct 1 ms 212 KB Output is correct
50 Correct 1 ms 300 KB Output is correct
51 Correct 0 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 2 ms 596 KB Output is correct
55 Correct 4 ms 700 KB Output is correct
56 Correct 136 ms 20072 KB Output is correct
57 Correct 213 ms 29404 KB Output is correct
58 Correct 204 ms 29356 KB Output is correct
59 Correct 0 ms 212 KB Output is correct
60 Correct 1 ms 212 KB Output is correct
61 Correct 1 ms 212 KB Output is correct
62 Correct 289 ms 39712 KB Output is correct
63 Correct 306 ms 39888 KB Output is correct
64 Correct 283 ms 39540 KB Output is correct
65 Correct 4 ms 852 KB Output is correct
66 Correct 7 ms 1528 KB Output is correct
67 Correct 130 ms 19944 KB Output is correct
68 Correct 207 ms 30576 KB Output is correct
69 Correct 359 ms 39820 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 212 KB Output is correct
2 Correct 1 ms 212 KB Output is correct
3 Correct 0 ms 300 KB Output is correct
4 Correct 1 ms 296 KB Output is correct
5 Correct 1 ms 300 KB Output is correct
6 Correct 0 ms 300 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 120 ms 19508 KB Output is correct
10 Correct 10 ms 2308 KB Output is correct
11 Correct 58 ms 10700 KB Output is correct
12 Correct 14 ms 3352 KB Output is correct
13 Correct 35 ms 7440 KB Output is correct
14 Correct 1 ms 468 KB Output is correct
15 Correct 2 ms 596 KB Output is correct
16 Correct 121 ms 19548 KB Output is correct
17 Correct 294 ms 40156 KB Output is correct
18 Correct 307 ms 40432 KB Output is correct
19 Correct 296 ms 40448 KB Output is correct
20 Correct 290 ms 41864 KB Output is correct
21 Correct 248 ms 36056 KB Output is correct
22 Correct 1 ms 212 KB Output is correct
23 Correct 37 ms 7076 KB Output is correct
24 Correct 19 ms 3792 KB Output is correct
25 Correct 71 ms 12976 KB Output is correct
26 Correct 142 ms 21160 KB Output is correct
27 Correct 134 ms 21892 KB Output is correct
28 Correct 177 ms 27024 KB Output is correct
29 Correct 233 ms 32600 KB Output is correct
30 Correct 259 ms 37396 KB Output is correct
31 Correct 310 ms 42600 KB Output is correct
32 Correct 324 ms 41516 KB Output is correct
33 Correct 288 ms 39772 KB Output is correct
34 Correct 4 ms 1108 KB Output is correct
35 Correct 8 ms 1848 KB Output is correct
36 Correct 130 ms 20448 KB Output is correct
37 Correct 261 ms 31128 KB Output is correct
38 Correct 298 ms 40696 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 212 KB Output is correct
2 Correct 1 ms 212 KB Output is correct
3 Correct 0 ms 300 KB Output is correct
4 Correct 1 ms 296 KB Output is correct
5 Correct 1 ms 300 KB Output is correct
6 Correct 0 ms 300 KB Output is correct
7 Correct 0 ms 212 KB Output is correct
8 Correct 1 ms 212 KB Output is correct
9 Correct 120 ms 19508 KB Output is correct
10 Correct 10 ms 2308 KB Output is correct
11 Correct 58 ms 10700 KB Output is correct
12 Correct 14 ms 3352 KB Output is correct
13 Correct 35 ms 7440 KB Output is correct
14 Correct 1 ms 468 KB Output is correct
15 Correct 2 ms 596 KB Output is correct
16 Correct 121 ms 19548 KB Output is correct
17 Correct 1 ms 212 KB Output is correct
18 Correct 1 ms 212 KB Output is correct
19 Correct 1 ms 300 KB Output is correct
20 Correct 0 ms 212 KB Output is correct
21 Correct 1 ms 212 KB Output is correct
22 Correct 0 ms 212 KB Output is correct
23 Correct 347 ms 40104 KB Output is correct
24 Correct 1 ms 212 KB Output is correct
25 Correct 2 ms 596 KB Output is correct
26 Correct 3 ms 724 KB Output is correct
27 Correct 4 ms 872 KB Output is correct
28 Correct 99 ms 16156 KB Output is correct
29 Correct 178 ms 24028 KB Output is correct
30 Correct 240 ms 32540 KB Output is correct
31 Correct 303 ms 40160 KB Output is correct
32 Correct 1 ms 300 KB Output is correct
33 Correct 1 ms 300 KB Output is correct
34 Correct 1 ms 212 KB Output is correct
35 Correct 0 ms 212 KB Output is correct
36 Correct 0 ms 296 KB Output is correct
37 Correct 0 ms 304 KB Output is correct
38 Correct 0 ms 296 KB Output is correct
39 Correct 0 ms 212 KB Output is correct
40 Correct 1 ms 212 KB Output is correct
41 Correct 1 ms 212 KB Output is correct
42 Correct 1 ms 212 KB Output is correct
43 Correct 3 ms 596 KB Output is correct
44 Correct 3 ms 728 KB Output is correct
45 Correct 121 ms 20172 KB Output is correct
46 Correct 191 ms 29804 KB Output is correct
47 Correct 200 ms 29720 KB Output is correct
48 Correct 1 ms 212 KB Output is correct
49 Correct 0 ms 296 KB Output is correct
50 Correct 0 ms 212 KB Output is correct
51 Correct 0 ms 212 KB Output is correct
52 Correct 1 ms 212 KB Output is correct
53 Correct 0 ms 300 KB Output is correct
54 Correct 0 ms 212 KB Output is correct
55 Correct 319 ms 40044 KB Output is correct
56 Correct 1 ms 212 KB Output is correct
57 Correct 2 ms 672 KB Output is correct
58 Correct 7 ms 1492 KB Output is correct
59 Correct 8 ms 1900 KB Output is correct
60 Correct 130 ms 19964 KB Output is correct
61 Correct 190 ms 28048 KB Output is correct
62 Correct 272 ms 33384 KB Output is correct
63 Correct 318 ms 40292 KB Output is correct
64 Correct 1 ms 212 KB Output is correct
65 Correct 0 ms 212 KB Output is correct
66 Correct 0 ms 212 KB Output is correct
67 Correct 273 ms 40104 KB Output is correct
68 Correct 271 ms 40056 KB Output is correct
69 Correct 289 ms 39904 KB Output is correct
70 Correct 3 ms 852 KB Output is correct
71 Correct 7 ms 1492 KB Output is correct
72 Correct 132 ms 20008 KB Output is correct
73 Correct 210 ms 30600 KB Output is correct
74 Correct 321 ms 40248 KB Output is correct
75 Correct 285 ms 41964 KB Output is correct
76 Correct 268 ms 40152 KB Output is correct
77 Correct 4 ms 1108 KB Output is correct
78 Correct 8 ms 1748 KB Output is correct
79 Correct 129 ms 20396 KB Output is correct
80 Correct 204 ms 31144 KB Output is correct
81 Correct 306 ms 41208 KB Output is correct
82 Correct 0 ms 212 KB Output is correct
83 Correct 0 ms 212 KB Output is correct
84 Correct 0 ms 212 KB Output is correct
85 Correct 280 ms 39836 KB Output is correct
86 Correct 287 ms 39496 KB Output is correct
87 Correct 297 ms 39620 KB Output is correct
88 Correct 239 ms 33716 KB Output is correct
89 Correct 151 ms 19936 KB Output is correct
90 Correct 241 ms 32664 KB Output is correct
91 Correct 213 ms 32576 KB Output is correct
92 Correct 261 ms 38732 KB Output is correct
93 Correct 260 ms 38824 KB Output is correct
94 Correct 296 ms 38756 KB Output is correct
95 Correct 288 ms 38724 KB Output is correct
96 Correct 1 ms 212 KB Output is correct
97 Correct 16 ms 3300 KB Output is correct
98 Correct 69 ms 10532 KB Output is correct
99 Correct 278 ms 39752 KB Output is correct
100 Correct 9 ms 2004 KB Output is correct
101 Correct 51 ms 8588 KB Output is correct
102 Correct 100 ms 16704 KB Output is correct
103 Correct 111 ms 16372 KB Output is correct
104 Correct 152 ms 21992 KB Output is correct
105 Correct 194 ms 28848 KB Output is correct
106 Correct 249 ms 34184 KB Output is correct
107 Correct 281 ms 39784 KB Output is correct
108 Correct 0 ms 212 KB Output is correct
109 Correct 0 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 0 ms 212 KB Output is correct
113 Correct 0 ms 304 KB Output is correct
114 Correct 1 ms 212 KB Output is correct
115 Correct 1 ms 300 KB Output is correct
116 Correct 0 ms 212 KB Output is correct
117 Correct 0 ms 212 KB Output is correct
118 Correct 1 ms 212 KB Output is correct
119 Correct 2 ms 596 KB Output is correct
120 Correct 4 ms 700 KB Output is correct
121 Correct 136 ms 20072 KB Output is correct
122 Correct 213 ms 29404 KB Output is correct
123 Correct 204 ms 29356 KB Output is correct
124 Correct 0 ms 212 KB Output is correct
125 Correct 1 ms 212 KB Output is correct
126 Correct 1 ms 212 KB Output is correct
127 Correct 289 ms 39712 KB Output is correct
128 Correct 306 ms 39888 KB Output is correct
129 Correct 283 ms 39540 KB Output is correct
130 Correct 4 ms 852 KB Output is correct
131 Correct 7 ms 1528 KB Output is correct
132 Correct 130 ms 19944 KB Output is correct
133 Correct 207 ms 30576 KB Output is correct
134 Correct 359 ms 39820 KB Output is correct
135 Correct 294 ms 40156 KB Output is correct
136 Correct 307 ms 40432 KB Output is correct
137 Correct 296 ms 40448 KB Output is correct
138 Correct 290 ms 41864 KB Output is correct
139 Correct 248 ms 36056 KB Output is correct
140 Correct 1 ms 212 KB Output is correct
141 Correct 37 ms 7076 KB Output is correct
142 Correct 19 ms 3792 KB Output is correct
143 Correct 71 ms 12976 KB Output is correct
144 Correct 142 ms 21160 KB Output is correct
145 Correct 134 ms 21892 KB Output is correct
146 Correct 177 ms 27024 KB Output is correct
147 Correct 233 ms 32600 KB Output is correct
148 Correct 259 ms 37396 KB Output is correct
149 Correct 310 ms 42600 KB Output is correct
150 Correct 324 ms 41516 KB Output is correct
151 Correct 288 ms 39772 KB Output is correct
152 Correct 4 ms 1108 KB Output is correct
153 Correct 8 ms 1848 KB Output is correct
154 Correct 130 ms 20448 KB Output is correct
155 Correct 261 ms 31128 KB Output is correct
156 Correct 298 ms 40696 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 1 ms 212 KB Output is correct
161 Correct 307 ms 40684 KB Output is correct
162 Correct 287 ms 41876 KB Output is correct
163 Correct 293 ms 41632 KB Output is correct
164 Correct 302 ms 41700 KB Output is correct
165 Correct 315 ms 41316 KB Output is correct
166 Correct 312 ms 40820 KB Output is correct
167 Correct 57 ms 9932 KB Output is correct
168 Correct 30 ms 5368 KB Output is correct
169 Correct 82 ms 13764 KB Output is correct
170 Correct 174 ms 25652 KB Output is correct
171 Correct 244 ms 33576 KB Output is correct
172 Correct 140 ms 21000 KB Output is correct
173 Correct 173 ms 25056 KB Output is correct
174 Correct 205 ms 30260 KB Output is correct
175 Correct 239 ms 33476 KB Output is correct
176 Correct 279 ms 37808 KB Output is correct
177 Correct 315 ms 41916 KB Output is correct