답안 #674723

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
674723 2022-12-26T01:27:43 Z vjudge1 철인 이종 경기 (APIO18_duathlon) C++17
100 / 100
61 ms 27692 KB
// =================================
//   author: memset0
//   date: 2018.12.12 23:54:19
//   website: https://memset0.cn/
// =================================
#include <bits/stdc++.h>
#define int long long
namespace ringo {
typedef long long ll;

template < class T > inline void read(T &x) {
    x = 0; register char c = getchar(); register bool f = 0;
    while (!isdigit(c)) f ^= c == '-', c = getchar();
    while (isdigit(c)) x = x * 10 + c - '0', c = getchar();
    if (f) x = -x;
}
template < class T > inline void print(T x) {
    if (x < 0) putchar('-'), x = -x;
    if (x > 9) print(x / 10);
    putchar('0' + x % 10);
}
template < class T > inline void maxd(T &a, T b) { if (b > a) a = b; }
template < class T > inline void mind(T &a, T b) { if (b < a) a = b; }
template < class T > inline void print(T x, char c) { print(x), putchar(c); }

const int N = 2e5 + 10, M = 8e5 + 10;
int n, m, top, tot, ans, tim, base;
int dfn[N], low[N], ins[N], stk[N], son[N], siz[N], val[N];

struct edge {
    int tot, flag, hed[N], nxt[M], to[M];
    edge () { tot = 2; }
    void link(int u, int v) {
        // if (flag) printf("link %d %d\n", u, v);
        nxt[tot] = hed[u], to[tot] = v, hed[u] = tot++;
        nxt[tot] = hed[v], to[tot] = u, hed[v] = tot++;
    }
} G1, G2;

void tarjan(int u, int father) {
    // printf("tarjan %d %d\n", u, father);
    ++base, dfn[u] = low[u] = ++tim, ins[u] = 1, stk[++top] = u;
    for (int i = G1.hed[u]; i; i = G1.nxt[i]) {
        int v = G1.to[i];
        if (v != father) {
            if (!dfn[v]) {
                tarjan(v, u), low[u] = std::min(low[u], low[v]);
                if (low[v] >= dfn[u]) {
                    G2.link(u, ++tot), ++val[tot]; int x;
                    do {
                        x = stk[top--], ins[x] = 0;
                        G2.link(x, tot), ++val[tot];
                    } while (x != v);
                }
            } else if (ins[v]) {
                low[u] = std::min(low[u], dfn[v]);
            }
        }
    }
}

void dfs(int u, int father) {
    // printf("dfs %d %d\n", u, father);
    if (u <= n) val[u] = -1, siz[u] = 1;
    int sum = 0;
    for (int i = G2.hed[u], v = G2.to[i]; i; i = G2.nxt[i], v = G2.to[i])
        if (v != father) {
            dfs(v, u);
            siz[u] += siz[v];
            sum += (ll)siz[v] * (base - siz[v]);
            // printf("%d %d => %d\n", u, val[u], (ll)val[u] * siz[v] * (base - siz[v]));
        }
    sum += (ll)(siz[u]) * (base - siz[u]);
    if (u <= n) sum += base - 1;
    ans += (ll)val[u] * sum;
    // printf("%d %d => %d\n", u, val[u], sum);
}

void main() {
    read(n), read(m);
    for (int i = 1, u, v; i <= m; i++) {
        read(u), read(v);
        G1.link(u, v);
    }
    tot = n;
    G2.flag = true;
    for (int i = 1; i <= n; i++)
        if (!dfn[i]) {
            base = 0;
            tarjan(i, 0);
            dfs(i, 0);
        }
    // for (int i = 1; i <= tot; i++) print(val[i], " \n"[i == tot]);
    // for (int i = 1; i <= tot; i++) print(siz[i], " \n"[i == tot]);
    print(ans, '\n');
}

} signed main() { return ringo::main(), 0; }

Compilation message

count_triplets.cpp: In function 'void ringo::read(T&)':
count_triplets.cpp:12:26: warning: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
   12 |     x = 0; register char c = getchar(); register bool f = 0;
      |                          ^
count_triplets.cpp:12:55: warning: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
   12 |     x = 0; register char c = getchar(); register bool f = 0;
      |                                                       ^
count_triplets.cpp: In instantiation of 'void ringo::read(T&) [with T = long long int]':
count_triplets.cpp:80:11:   required from here
count_triplets.cpp:12:26: warning: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
   12 |     x = 0; register char c = getchar(); register bool f = 0;
      |                          ^
count_triplets.cpp:12:55: warning: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
   12 |     x = 0; register char c = getchar(); register bool f = 0;
      |                                                       ^
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 340 KB Output is correct
2 Correct 1 ms 340 KB Output is correct
3 Correct 1 ms 316 KB Output is correct
4 Correct 1 ms 340 KB Output is correct
5 Correct 1 ms 340 KB Output is correct
6 Correct 1 ms 340 KB Output is correct
7 Correct 1 ms 340 KB Output is correct
8 Correct 1 ms 312 KB Output is correct
9 Correct 1 ms 340 KB Output is correct
10 Correct 1 ms 340 KB Output is correct
11 Correct 1 ms 340 KB Output is correct
12 Correct 1 ms 340 KB Output is correct
13 Correct 1 ms 340 KB Output is correct
14 Correct 1 ms 340 KB Output is correct
15 Correct 1 ms 340 KB Output is correct
16 Correct 1 ms 340 KB Output is correct
17 Correct 1 ms 340 KB Output is correct
18 Correct 1 ms 340 KB Output is correct
19 Correct 1 ms 316 KB Output is correct
20 Correct 0 ms 340 KB Output is correct
21 Correct 1 ms 340 KB Output is correct
22 Correct 0 ms 312 KB Output is correct
23 Correct 1 ms 316 KB Output is correct
24 Correct 1 ms 340 KB Output is correct
25 Correct 0 ms 312 KB Output is correct
26 Correct 1 ms 316 KB Output is correct
27 Correct 1 ms 340 KB Output is correct
28 Correct 1 ms 316 KB Output is correct
29 Correct 1 ms 340 KB Output is correct
30 Correct 0 ms 340 KB Output is correct
31 Correct 1 ms 340 KB Output is correct
32 Correct 1 ms 340 KB Output is correct
33 Correct 0 ms 340 KB Output is correct
34 Correct 1 ms 340 KB Output is correct
35 Correct 1 ms 316 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 340 KB Output is correct
2 Correct 1 ms 340 KB Output is correct
3 Correct 1 ms 316 KB Output is correct
4 Correct 1 ms 340 KB Output is correct
5 Correct 1 ms 340 KB Output is correct
6 Correct 1 ms 340 KB Output is correct
7 Correct 1 ms 340 KB Output is correct
8 Correct 1 ms 312 KB Output is correct
9 Correct 1 ms 340 KB Output is correct
10 Correct 1 ms 340 KB Output is correct
11 Correct 1 ms 340 KB Output is correct
12 Correct 1 ms 340 KB Output is correct
13 Correct 1 ms 340 KB Output is correct
14 Correct 1 ms 340 KB Output is correct
15 Correct 1 ms 340 KB Output is correct
16 Correct 1 ms 340 KB Output is correct
17 Correct 1 ms 340 KB Output is correct
18 Correct 1 ms 340 KB Output is correct
19 Correct 1 ms 316 KB Output is correct
20 Correct 0 ms 340 KB Output is correct
21 Correct 1 ms 340 KB Output is correct
22 Correct 0 ms 312 KB Output is correct
23 Correct 1 ms 316 KB Output is correct
24 Correct 1 ms 340 KB Output is correct
25 Correct 0 ms 312 KB Output is correct
26 Correct 1 ms 316 KB Output is correct
27 Correct 1 ms 340 KB Output is correct
28 Correct 1 ms 316 KB Output is correct
29 Correct 1 ms 340 KB Output is correct
30 Correct 0 ms 340 KB Output is correct
31 Correct 1 ms 340 KB Output is correct
32 Correct 1 ms 340 KB Output is correct
33 Correct 0 ms 340 KB Output is correct
34 Correct 1 ms 340 KB Output is correct
35 Correct 1 ms 316 KB Output is correct
36 Correct 1 ms 340 KB Output is correct
37 Correct 1 ms 340 KB Output is correct
38 Correct 1 ms 320 KB Output is correct
39 Correct 1 ms 340 KB Output is correct
40 Correct 1 ms 316 KB Output is correct
41 Correct 1 ms 340 KB Output is correct
42 Correct 1 ms 340 KB Output is correct
43 Correct 1 ms 340 KB Output is correct
44 Correct 1 ms 340 KB Output is correct
45 Correct 1 ms 340 KB Output is correct
46 Correct 0 ms 320 KB Output is correct
47 Correct 0 ms 340 KB Output is correct
48 Correct 1 ms 340 KB Output is correct
49 Correct 1 ms 340 KB Output is correct
50 Correct 1 ms 340 KB Output is correct
51 Correct 1 ms 340 KB Output is correct
52 Correct 0 ms 340 KB Output is correct
53 Correct 0 ms 340 KB Output is correct
54 Correct 1 ms 340 KB Output is correct
55 Correct 1 ms 340 KB Output is correct
56 Correct 1 ms 340 KB Output is correct
57 Correct 1 ms 312 KB Output is correct
58 Correct 1 ms 340 KB Output is correct
59 Correct 1 ms 348 KB Output is correct
60 Correct 1 ms 312 KB Output is correct
61 Correct 1 ms 340 KB Output is correct
62 Correct 1 ms 320 KB Output is correct
63 Correct 0 ms 340 KB Output is correct
64 Correct 1 ms 340 KB Output is correct
65 Correct 1 ms 340 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 35 ms 25040 KB Output is correct
2 Correct 33 ms 25040 KB Output is correct
3 Correct 41 ms 22920 KB Output is correct
4 Correct 36 ms 23460 KB Output is correct
5 Correct 35 ms 19532 KB Output is correct
6 Correct 42 ms 21792 KB Output is correct
7 Correct 50 ms 19692 KB Output is correct
8 Correct 50 ms 20276 KB Output is correct
9 Correct 44 ms 18248 KB Output is correct
10 Correct 36 ms 18368 KB Output is correct
11 Correct 26 ms 14724 KB Output is correct
12 Correct 26 ms 14580 KB Output is correct
13 Correct 31 ms 14128 KB Output is correct
14 Correct 26 ms 13996 KB Output is correct
15 Correct 17 ms 12492 KB Output is correct
16 Correct 21 ms 12332 KB Output is correct
17 Correct 5 ms 6404 KB Output is correct
18 Correct 5 ms 6460 KB Output is correct
19 Correct 4 ms 6228 KB Output is correct
20 Correct 4 ms 6228 KB Output is correct
21 Correct 4 ms 5972 KB Output is correct
22 Correct 4 ms 5972 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 468 KB Output is correct
2 Correct 1 ms 452 KB Output is correct
3 Correct 1 ms 512 KB Output is correct
4 Correct 1 ms 576 KB Output is correct
5 Correct 1 ms 596 KB Output is correct
6 Correct 1 ms 596 KB Output is correct
7 Correct 1 ms 580 KB Output is correct
8 Correct 1 ms 596 KB Output is correct
9 Correct 1 ms 596 KB Output is correct
10 Correct 1 ms 468 KB Output is correct
11 Correct 1 ms 468 KB Output is correct
12 Correct 1 ms 468 KB Output is correct
13 Correct 1 ms 576 KB Output is correct
14 Correct 1 ms 468 KB Output is correct
15 Correct 1 ms 448 KB Output is correct
16 Correct 1 ms 468 KB Output is correct
17 Correct 2 ms 468 KB Output is correct
18 Correct 1 ms 468 KB Output is correct
19 Correct 1 ms 468 KB Output is correct
20 Correct 1 ms 468 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 33 ms 18816 KB Output is correct
2 Correct 32 ms 18780 KB Output is correct
3 Correct 33 ms 18796 KB Output is correct
4 Correct 34 ms 18792 KB Output is correct
5 Correct 32 ms 18736 KB Output is correct
6 Correct 54 ms 27692 KB Output is correct
7 Correct 42 ms 24708 KB Output is correct
8 Correct 43 ms 23368 KB Output is correct
9 Correct 39 ms 21708 KB Output is correct
10 Correct 33 ms 18776 KB Output is correct
11 Correct 32 ms 18792 KB Output is correct
12 Correct 34 ms 18764 KB Output is correct
13 Correct 40 ms 18760 KB Output is correct
14 Correct 35 ms 17584 KB Output is correct
15 Correct 28 ms 16332 KB Output is correct
16 Correct 17 ms 12624 KB Output is correct
17 Correct 19 ms 18748 KB Output is correct
18 Correct 20 ms 18760 KB Output is correct
19 Correct 25 ms 18892 KB Output is correct
20 Correct 27 ms 18804 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 468 KB Output is correct
2 Correct 1 ms 580 KB Output is correct
3 Correct 1 ms 452 KB Output is correct
4 Correct 1 ms 468 KB Output is correct
5 Correct 1 ms 468 KB Output is correct
6 Correct 1 ms 468 KB Output is correct
7 Correct 1 ms 468 KB Output is correct
8 Correct 1 ms 468 KB Output is correct
9 Correct 1 ms 468 KB Output is correct
10 Correct 1 ms 468 KB Output is correct
11 Correct 1 ms 452 KB Output is correct
12 Correct 1 ms 596 KB Output is correct
13 Correct 1 ms 596 KB Output is correct
14 Correct 1 ms 596 KB Output is correct
15 Correct 1 ms 596 KB Output is correct
16 Correct 1 ms 468 KB Output is correct
17 Correct 1 ms 468 KB Output is correct
18 Correct 1 ms 468 KB Output is correct
19 Correct 1 ms 468 KB Output is correct
20 Correct 1 ms 452 KB Output is correct
21 Correct 1 ms 468 KB Output is correct
22 Correct 1 ms 468 KB Output is correct
23 Correct 1 ms 468 KB Output is correct
24 Correct 1 ms 468 KB Output is correct
25 Correct 1 ms 444 KB Output is correct
26 Correct 1 ms 340 KB Output is correct
27 Correct 1 ms 448 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 35 ms 18760 KB Output is correct
2 Correct 30 ms 18808 KB Output is correct
3 Correct 44 ms 18584 KB Output is correct
4 Correct 38 ms 17484 KB Output is correct
5 Correct 35 ms 15836 KB Output is correct
6 Correct 30 ms 15192 KB Output is correct
7 Correct 28 ms 14724 KB Output is correct
8 Correct 36 ms 14288 KB Output is correct
9 Correct 27 ms 14028 KB Output is correct
10 Correct 31 ms 13948 KB Output is correct
11 Correct 26 ms 13696 KB Output is correct
12 Correct 27 ms 13624 KB Output is correct
13 Correct 28 ms 13732 KB Output is correct
14 Correct 28 ms 15824 KB Output is correct
15 Correct 42 ms 24788 KB Output is correct
16 Correct 41 ms 22760 KB Output is correct
17 Correct 43 ms 23404 KB Output is correct
18 Correct 52 ms 21556 KB Output is correct
19 Correct 35 ms 17480 KB Output is correct
20 Correct 40 ms 17484 KB Output is correct
21 Correct 39 ms 17484 KB Output is correct
22 Correct 37 ms 16168 KB Output is correct
23 Correct 33 ms 15052 KB Output is correct
24 Correct 30 ms 18636 KB Output is correct
25 Correct 34 ms 18640 KB Output is correct
26 Correct 30 ms 18116 KB Output is correct
27 Correct 33 ms 18120 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 340 KB Output is correct
2 Correct 1 ms 340 KB Output is correct
3 Correct 1 ms 316 KB Output is correct
4 Correct 1 ms 340 KB Output is correct
5 Correct 1 ms 340 KB Output is correct
6 Correct 1 ms 340 KB Output is correct
7 Correct 1 ms 340 KB Output is correct
8 Correct 1 ms 312 KB Output is correct
9 Correct 1 ms 340 KB Output is correct
10 Correct 1 ms 340 KB Output is correct
11 Correct 1 ms 340 KB Output is correct
12 Correct 1 ms 340 KB Output is correct
13 Correct 1 ms 340 KB Output is correct
14 Correct 1 ms 340 KB Output is correct
15 Correct 1 ms 340 KB Output is correct
16 Correct 1 ms 340 KB Output is correct
17 Correct 1 ms 340 KB Output is correct
18 Correct 1 ms 340 KB Output is correct
19 Correct 1 ms 316 KB Output is correct
20 Correct 0 ms 340 KB Output is correct
21 Correct 1 ms 340 KB Output is correct
22 Correct 0 ms 312 KB Output is correct
23 Correct 1 ms 316 KB Output is correct
24 Correct 1 ms 340 KB Output is correct
25 Correct 0 ms 312 KB Output is correct
26 Correct 1 ms 316 KB Output is correct
27 Correct 1 ms 340 KB Output is correct
28 Correct 1 ms 316 KB Output is correct
29 Correct 1 ms 340 KB Output is correct
30 Correct 0 ms 340 KB Output is correct
31 Correct 1 ms 340 KB Output is correct
32 Correct 1 ms 340 KB Output is correct
33 Correct 0 ms 340 KB Output is correct
34 Correct 1 ms 340 KB Output is correct
35 Correct 1 ms 316 KB Output is correct
36 Correct 1 ms 340 KB Output is correct
37 Correct 1 ms 340 KB Output is correct
38 Correct 1 ms 320 KB Output is correct
39 Correct 1 ms 340 KB Output is correct
40 Correct 1 ms 316 KB Output is correct
41 Correct 1 ms 340 KB Output is correct
42 Correct 1 ms 340 KB Output is correct
43 Correct 1 ms 340 KB Output is correct
44 Correct 1 ms 340 KB Output is correct
45 Correct 1 ms 340 KB Output is correct
46 Correct 0 ms 320 KB Output is correct
47 Correct 0 ms 340 KB Output is correct
48 Correct 1 ms 340 KB Output is correct
49 Correct 1 ms 340 KB Output is correct
50 Correct 1 ms 340 KB Output is correct
51 Correct 1 ms 340 KB Output is correct
52 Correct 0 ms 340 KB Output is correct
53 Correct 0 ms 340 KB Output is correct
54 Correct 1 ms 340 KB Output is correct
55 Correct 1 ms 340 KB Output is correct
56 Correct 1 ms 340 KB Output is correct
57 Correct 1 ms 312 KB Output is correct
58 Correct 1 ms 340 KB Output is correct
59 Correct 1 ms 348 KB Output is correct
60 Correct 1 ms 312 KB Output is correct
61 Correct 1 ms 340 KB Output is correct
62 Correct 1 ms 320 KB Output is correct
63 Correct 0 ms 340 KB Output is correct
64 Correct 1 ms 340 KB Output is correct
65 Correct 1 ms 340 KB Output is correct
66 Correct 1 ms 340 KB Output is correct
67 Correct 1 ms 468 KB Output is correct
68 Correct 1 ms 448 KB Output is correct
69 Correct 1 ms 596 KB Output is correct
70 Correct 1 ms 596 KB Output is correct
71 Correct 1 ms 448 KB Output is correct
72 Correct 1 ms 468 KB Output is correct
73 Correct 1 ms 468 KB Output is correct
74 Correct 1 ms 468 KB Output is correct
75 Correct 1 ms 468 KB Output is correct
76 Correct 1 ms 340 KB Output is correct
77 Correct 1 ms 468 KB Output is correct
78 Correct 1 ms 468 KB Output is correct
79 Correct 1 ms 456 KB Output is correct
80 Correct 1 ms 452 KB Output is correct
81 Correct 1 ms 468 KB Output is correct
82 Correct 1 ms 468 KB Output is correct
83 Correct 1 ms 596 KB Output is correct
84 Correct 1 ms 468 KB Output is correct
85 Correct 1 ms 468 KB Output is correct
86 Correct 1 ms 468 KB Output is correct
87 Correct 1 ms 468 KB Output is correct
88 Correct 1 ms 468 KB Output is correct
89 Correct 1 ms 452 KB Output is correct
90 Correct 1 ms 452 KB Output is correct
91 Correct 1 ms 456 KB Output is correct
92 Correct 1 ms 468 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 1 ms 340 KB Output is correct
2 Correct 1 ms 340 KB Output is correct
3 Correct 1 ms 316 KB Output is correct
4 Correct 1 ms 340 KB Output is correct
5 Correct 1 ms 340 KB Output is correct
6 Correct 1 ms 340 KB Output is correct
7 Correct 1 ms 340 KB Output is correct
8 Correct 1 ms 312 KB Output is correct
9 Correct 1 ms 340 KB Output is correct
10 Correct 1 ms 340 KB Output is correct
11 Correct 1 ms 340 KB Output is correct
12 Correct 1 ms 340 KB Output is correct
13 Correct 1 ms 340 KB Output is correct
14 Correct 1 ms 340 KB Output is correct
15 Correct 1 ms 340 KB Output is correct
16 Correct 1 ms 340 KB Output is correct
17 Correct 1 ms 340 KB Output is correct
18 Correct 1 ms 340 KB Output is correct
19 Correct 1 ms 316 KB Output is correct
20 Correct 0 ms 340 KB Output is correct
21 Correct 1 ms 340 KB Output is correct
22 Correct 0 ms 312 KB Output is correct
23 Correct 1 ms 316 KB Output is correct
24 Correct 1 ms 340 KB Output is correct
25 Correct 0 ms 312 KB Output is correct
26 Correct 1 ms 316 KB Output is correct
27 Correct 1 ms 340 KB Output is correct
28 Correct 1 ms 316 KB Output is correct
29 Correct 1 ms 340 KB Output is correct
30 Correct 0 ms 340 KB Output is correct
31 Correct 1 ms 340 KB Output is correct
32 Correct 1 ms 340 KB Output is correct
33 Correct 0 ms 340 KB Output is correct
34 Correct 1 ms 340 KB Output is correct
35 Correct 1 ms 316 KB Output is correct
36 Correct 1 ms 340 KB Output is correct
37 Correct 1 ms 340 KB Output is correct
38 Correct 1 ms 320 KB Output is correct
39 Correct 1 ms 340 KB Output is correct
40 Correct 1 ms 316 KB Output is correct
41 Correct 1 ms 340 KB Output is correct
42 Correct 1 ms 340 KB Output is correct
43 Correct 1 ms 340 KB Output is correct
44 Correct 1 ms 340 KB Output is correct
45 Correct 1 ms 340 KB Output is correct
46 Correct 0 ms 320 KB Output is correct
47 Correct 0 ms 340 KB Output is correct
48 Correct 1 ms 340 KB Output is correct
49 Correct 1 ms 340 KB Output is correct
50 Correct 1 ms 340 KB Output is correct
51 Correct 1 ms 340 KB Output is correct
52 Correct 0 ms 340 KB Output is correct
53 Correct 0 ms 340 KB Output is correct
54 Correct 1 ms 340 KB Output is correct
55 Correct 1 ms 340 KB Output is correct
56 Correct 1 ms 340 KB Output is correct
57 Correct 1 ms 312 KB Output is correct
58 Correct 1 ms 340 KB Output is correct
59 Correct 1 ms 348 KB Output is correct
60 Correct 1 ms 312 KB Output is correct
61 Correct 1 ms 340 KB Output is correct
62 Correct 1 ms 320 KB Output is correct
63 Correct 0 ms 340 KB Output is correct
64 Correct 1 ms 340 KB Output is correct
65 Correct 1 ms 340 KB Output is correct
66 Correct 35 ms 25040 KB Output is correct
67 Correct 33 ms 25040 KB Output is correct
68 Correct 41 ms 22920 KB Output is correct
69 Correct 36 ms 23460 KB Output is correct
70 Correct 35 ms 19532 KB Output is correct
71 Correct 42 ms 21792 KB Output is correct
72 Correct 50 ms 19692 KB Output is correct
73 Correct 50 ms 20276 KB Output is correct
74 Correct 44 ms 18248 KB Output is correct
75 Correct 36 ms 18368 KB Output is correct
76 Correct 26 ms 14724 KB Output is correct
77 Correct 26 ms 14580 KB Output is correct
78 Correct 31 ms 14128 KB Output is correct
79 Correct 26 ms 13996 KB Output is correct
80 Correct 17 ms 12492 KB Output is correct
81 Correct 21 ms 12332 KB Output is correct
82 Correct 5 ms 6404 KB Output is correct
83 Correct 5 ms 6460 KB Output is correct
84 Correct 4 ms 6228 KB Output is correct
85 Correct 4 ms 6228 KB Output is correct
86 Correct 4 ms 5972 KB Output is correct
87 Correct 4 ms 5972 KB Output is correct
88 Correct 1 ms 468 KB Output is correct
89 Correct 1 ms 452 KB Output is correct
90 Correct 1 ms 512 KB Output is correct
91 Correct 1 ms 576 KB Output is correct
92 Correct 1 ms 596 KB Output is correct
93 Correct 1 ms 596 KB Output is correct
94 Correct 1 ms 580 KB Output is correct
95 Correct 1 ms 596 KB Output is correct
96 Correct 1 ms 596 KB Output is correct
97 Correct 1 ms 468 KB Output is correct
98 Correct 1 ms 468 KB Output is correct
99 Correct 1 ms 468 KB Output is correct
100 Correct 1 ms 576 KB Output is correct
101 Correct 1 ms 468 KB Output is correct
102 Correct 1 ms 448 KB Output is correct
103 Correct 1 ms 468 KB Output is correct
104 Correct 2 ms 468 KB Output is correct
105 Correct 1 ms 468 KB Output is correct
106 Correct 1 ms 468 KB Output is correct
107 Correct 1 ms 468 KB Output is correct
108 Correct 33 ms 18816 KB Output is correct
109 Correct 32 ms 18780 KB Output is correct
110 Correct 33 ms 18796 KB Output is correct
111 Correct 34 ms 18792 KB Output is correct
112 Correct 32 ms 18736 KB Output is correct
113 Correct 54 ms 27692 KB Output is correct
114 Correct 42 ms 24708 KB Output is correct
115 Correct 43 ms 23368 KB Output is correct
116 Correct 39 ms 21708 KB Output is correct
117 Correct 33 ms 18776 KB Output is correct
118 Correct 32 ms 18792 KB Output is correct
119 Correct 34 ms 18764 KB Output is correct
120 Correct 40 ms 18760 KB Output is correct
121 Correct 35 ms 17584 KB Output is correct
122 Correct 28 ms 16332 KB Output is correct
123 Correct 17 ms 12624 KB Output is correct
124 Correct 19 ms 18748 KB Output is correct
125 Correct 20 ms 18760 KB Output is correct
126 Correct 25 ms 18892 KB Output is correct
127 Correct 27 ms 18804 KB Output is correct
128 Correct 1 ms 468 KB Output is correct
129 Correct 1 ms 580 KB Output is correct
130 Correct 1 ms 452 KB Output is correct
131 Correct 1 ms 468 KB Output is correct
132 Correct 1 ms 468 KB Output is correct
133 Correct 1 ms 468 KB Output is correct
134 Correct 1 ms 468 KB Output is correct
135 Correct 1 ms 468 KB Output is correct
136 Correct 1 ms 468 KB Output is correct
137 Correct 1 ms 468 KB Output is correct
138 Correct 1 ms 452 KB Output is correct
139 Correct 1 ms 596 KB Output is correct
140 Correct 1 ms 596 KB Output is correct
141 Correct 1 ms 596 KB Output is correct
142 Correct 1 ms 596 KB Output is correct
143 Correct 1 ms 468 KB Output is correct
144 Correct 1 ms 468 KB Output is correct
145 Correct 1 ms 468 KB Output is correct
146 Correct 1 ms 468 KB Output is correct
147 Correct 1 ms 452 KB Output is correct
148 Correct 1 ms 468 KB Output is correct
149 Correct 1 ms 468 KB Output is correct
150 Correct 1 ms 468 KB Output is correct
151 Correct 1 ms 468 KB Output is correct
152 Correct 1 ms 444 KB Output is correct
153 Correct 1 ms 340 KB Output is correct
154 Correct 1 ms 448 KB Output is correct
155 Correct 35 ms 18760 KB Output is correct
156 Correct 30 ms 18808 KB Output is correct
157 Correct 44 ms 18584 KB Output is correct
158 Correct 38 ms 17484 KB Output is correct
159 Correct 35 ms 15836 KB Output is correct
160 Correct 30 ms 15192 KB Output is correct
161 Correct 28 ms 14724 KB Output is correct
162 Correct 36 ms 14288 KB Output is correct
163 Correct 27 ms 14028 KB Output is correct
164 Correct 31 ms 13948 KB Output is correct
165 Correct 26 ms 13696 KB Output is correct
166 Correct 27 ms 13624 KB Output is correct
167 Correct 28 ms 13732 KB Output is correct
168 Correct 28 ms 15824 KB Output is correct
169 Correct 42 ms 24788 KB Output is correct
170 Correct 41 ms 22760 KB Output is correct
171 Correct 43 ms 23404 KB Output is correct
172 Correct 52 ms 21556 KB Output is correct
173 Correct 35 ms 17480 KB Output is correct
174 Correct 40 ms 17484 KB Output is correct
175 Correct 39 ms 17484 KB Output is correct
176 Correct 37 ms 16168 KB Output is correct
177 Correct 33 ms 15052 KB Output is correct
178 Correct 30 ms 18636 KB Output is correct
179 Correct 34 ms 18640 KB Output is correct
180 Correct 30 ms 18116 KB Output is correct
181 Correct 33 ms 18120 KB Output is correct
182 Correct 1 ms 340 KB Output is correct
183 Correct 1 ms 468 KB Output is correct
184 Correct 1 ms 448 KB Output is correct
185 Correct 1 ms 596 KB Output is correct
186 Correct 1 ms 596 KB Output is correct
187 Correct 1 ms 448 KB Output is correct
188 Correct 1 ms 468 KB Output is correct
189 Correct 1 ms 468 KB Output is correct
190 Correct 1 ms 468 KB Output is correct
191 Correct 1 ms 468 KB Output is correct
192 Correct 1 ms 340 KB Output is correct
193 Correct 1 ms 468 KB Output is correct
194 Correct 1 ms 468 KB Output is correct
195 Correct 1 ms 456 KB Output is correct
196 Correct 1 ms 452 KB Output is correct
197 Correct 1 ms 468 KB Output is correct
198 Correct 1 ms 468 KB Output is correct
199 Correct 1 ms 596 KB Output is correct
200 Correct 1 ms 468 KB Output is correct
201 Correct 1 ms 468 KB Output is correct
202 Correct 1 ms 468 KB Output is correct
203 Correct 1 ms 468 KB Output is correct
204 Correct 1 ms 468 KB Output is correct
205 Correct 1 ms 452 KB Output is correct
206 Correct 1 ms 452 KB Output is correct
207 Correct 1 ms 456 KB Output is correct
208 Correct 1 ms 468 KB Output is correct
209 Correct 4 ms 5052 KB Output is correct
210 Correct 18 ms 12744 KB Output is correct
211 Correct 38 ms 18072 KB Output is correct
212 Correct 42 ms 22028 KB Output is correct
213 Correct 61 ms 25296 KB Output is correct
214 Correct 18 ms 15596 KB Output is correct
215 Correct 21 ms 15556 KB Output is correct
216 Correct 38 ms 18388 KB Output is correct
217 Correct 32 ms 16852 KB Output is correct
218 Correct 39 ms 14548 KB Output is correct
219 Correct 28 ms 13980 KB Output is correct
220 Correct 31 ms 13708 KB Output is correct
221 Correct 34 ms 13632 KB Output is correct
222 Correct 45 ms 16780 KB Output is correct
223 Correct 58 ms 20428 KB Output is correct
224 Correct 39 ms 19428 KB Output is correct
225 Correct 38 ms 16540 KB Output is correct
226 Correct 35 ms 16576 KB Output is correct
227 Correct 36 ms 16588 KB Output is correct
228 Correct 32 ms 15560 KB Output is correct
229 Correct 29 ms 14632 KB Output is correct
230 Correct 34 ms 17264 KB Output is correct
231 Correct 35 ms 17176 KB Output is correct