답안 #233312

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
233312 2020-05-20T09:00:18 Z Ruxandra985 철인 이종 경기 (APIO18_duathlon) C++14
100 / 100
246 ms 55288 KB
#include <bits/stdc++.h>
#define DIMN 200005
#define DIMM 200005
using namespace std;
long long low[DIMN] , bicnx , lvl[DIMN] , taken[DIMN] , f[DIMN] , under[DIMN] , two[DIMN];
stack <long long> st;
vector <long long> v[DIMN] , w[2 * DIMN];
set <long long> sol[DIMN];
long long x , n , val;
void dfs_bic (long long nod,long long tt){
    long long i,vecin;
    low[nod]=lvl[nod];
    st.push(nod);
    for (i=0;i<v[nod].size();i++){
        vecin=v[nod][i];
        if (vecin==tt)
            continue;
        if (lvl[vecin]==0){
            lvl[vecin]=1+lvl[nod];
            dfs_bic(vecin,nod);
            low[nod]=min(low[nod],low[vecin]);
            if (low[vecin]>=lvl[nod]){ /// nod e un nod critic
                bicnx++;
                do{
                    x=st.top();
                    taken[x]++;
                    st.pop();
                    sol[bicnx].insert(x);
                }
                while (x!=vecin);
                sol[bicnx].insert(nod);
                taken[nod]++;
                /// am scos din stiva muchiile care sunt in subarborele nod->vecin
            }
        }
        else low[nod]=min(low[nod],lvl[vecin]);
    }
}


void precalc (long long nod , long long tt){

    long long i , vecin;

    if (nod <= n){ /// nod

        under[nod] = 1;

    }
    else under[nod] = 0;

    for (i = 0 ; i < w[nod].size() ; i++){
        vecin = w[nod][i];
        if (vecin != tt){

            precalc (vecin , nod);

            under[nod] += under[vecin];

            if (nod > n){
                two[nod] += under[vecin] * (under[vecin] - 1);
            }


        }
    }

}

void dfs (long long root , long long nod , long long tt){
    long long i , vecin;

    f[nod] = 1;

    for (i = 0 ; i < w[nod].size() ; i++){
        vecin = w[nod][i];
        if (vecin != tt){

            dfs (root , vecin , nod);

        }
    }

    //if (nod == 5)
      //  printf ("a");

    if (nod <= n){ /// nod

        for (i = 0 ; i < w[nod].size() ; i++){
            vecin = w[nod][i];
            if (vecin != tt){

                val -= two[vecin];

                /// din vecin -> nod -> din vecin

            }
        }

    }
    else { /// componenta

        for (i = 0 ; i < w[nod].size() ; i++){
            vecin = w[nod][i];
            if (vecin != tt){

                val -= two[nod] - under[vecin] * (under[vecin] - 1) + (under[root] - under[nod]) * (under[root] - under[nod] - 1);

            }
        }

    }


}

int main()
{
    FILE *fin = stdin;
    FILE *fout = stdout;
    long long m , i , x , y , nod;
    fscanf (fin,"%lld%lld",&n,&m);
    for (i=1;i<=m;i++){
        fscanf (fin,"%lld%lld",&x,&y);
        v[x].push_back(y);
        v[y].push_back(x);
    }

    for (i = 1 ; i <= n ; i++){
        if (!lvl[i]){

            lvl[i] = 1;
            dfs_bic (i , 0);

        }

    }

    for (i = 1 ; i <= bicnx ; i++){

        for (set <long long> :: iterator it = sol[i].begin() ; it != sol[i].end() ; it++){

            nod = *it;

            w[nod].push_back(n + i);
            w[n + i].push_back(nod);

            //fprintf (fout,"%lld %lld\n" , nod , n + i);

        }

    }

    for (i = 1 ; i <= n ; i++){
        if (!f[i]){
            precalc(i , 0);
            dfs(i , i , 0);
            val += under[i] * (under[i] - 1) * (under[i] - 2);
        }
    }

    fprintf (fout,"%lld",val);

    return 0;
}

Compilation message

count_triplets.cpp: In function 'void dfs_bic(long long int, long long int)':
count_triplets.cpp:14:15: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for (i=0;i<v[nod].size();i++){
              ~^~~~~~~~~~~~~~
count_triplets.cpp: In function 'void precalc(long long int, long long int)':
count_triplets.cpp:52:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for (i = 0 ; i < w[nod].size() ; i++){
                  ~~^~~~~~~~~~~~~~~
count_triplets.cpp: In function 'void dfs(long long int, long long int, long long int)':
count_triplets.cpp:75:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for (i = 0 ; i < w[nod].size() ; i++){
                  ~~^~~~~~~~~~~~~~~
count_triplets.cpp:89:24: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         for (i = 0 ; i < w[nod].size() ; i++){
                      ~~^~~~~~~~~~~~~~~
count_triplets.cpp:103:24: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
         for (i = 0 ; i < w[nod].size() ; i++){
                      ~~^~~~~~~~~~~~~~~
count_triplets.cpp: In function 'int main()':
count_triplets.cpp:122:12: warning: ignoring return value of 'int fscanf(FILE*, const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
     fscanf (fin,"%lld%lld",&n,&m);
     ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
count_triplets.cpp:124:16: warning: ignoring return value of 'int fscanf(FILE*, const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
         fscanf (fin,"%lld%lld",&x,&y);
         ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
# 결과 실행 시간 메모리 Grader output
1 Correct 18 ms 23808 KB Output is correct
2 Correct 23 ms 23808 KB Output is correct
3 Correct 18 ms 23808 KB Output is correct
4 Correct 19 ms 23808 KB Output is correct
5 Correct 19 ms 23856 KB Output is correct
6 Correct 18 ms 23808 KB Output is correct
7 Correct 19 ms 23808 KB Output is correct
8 Correct 19 ms 23808 KB Output is correct
9 Correct 18 ms 23808 KB Output is correct
10 Correct 20 ms 23808 KB Output is correct
11 Correct 19 ms 23808 KB Output is correct
12 Correct 18 ms 23808 KB Output is correct
13 Correct 24 ms 23904 KB Output is correct
14 Correct 18 ms 23808 KB Output is correct
15 Correct 20 ms 23808 KB Output is correct
16 Correct 18 ms 23808 KB Output is correct
17 Correct 19 ms 23808 KB Output is correct
18 Correct 19 ms 23936 KB Output is correct
19 Correct 18 ms 23784 KB Output is correct
20 Correct 24 ms 23856 KB Output is correct
21 Correct 19 ms 23808 KB Output is correct
22 Correct 18 ms 23808 KB Output is correct
23 Correct 19 ms 23808 KB Output is correct
24 Correct 19 ms 23784 KB Output is correct
25 Correct 21 ms 23808 KB Output is correct
26 Correct 19 ms 23808 KB Output is correct
27 Correct 20 ms 23808 KB Output is correct
28 Correct 18 ms 23784 KB Output is correct
29 Correct 21 ms 23808 KB Output is correct
30 Correct 20 ms 23808 KB Output is correct
31 Correct 20 ms 23808 KB Output is correct
32 Correct 23 ms 23936 KB Output is correct
33 Correct 21 ms 23808 KB Output is correct
34 Correct 18 ms 23808 KB Output is correct
35 Correct 19 ms 23808 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 18 ms 23808 KB Output is correct
2 Correct 23 ms 23808 KB Output is correct
3 Correct 18 ms 23808 KB Output is correct
4 Correct 19 ms 23808 KB Output is correct
5 Correct 19 ms 23856 KB Output is correct
6 Correct 18 ms 23808 KB Output is correct
7 Correct 19 ms 23808 KB Output is correct
8 Correct 19 ms 23808 KB Output is correct
9 Correct 18 ms 23808 KB Output is correct
10 Correct 20 ms 23808 KB Output is correct
11 Correct 19 ms 23808 KB Output is correct
12 Correct 18 ms 23808 KB Output is correct
13 Correct 24 ms 23904 KB Output is correct
14 Correct 18 ms 23808 KB Output is correct
15 Correct 20 ms 23808 KB Output is correct
16 Correct 18 ms 23808 KB Output is correct
17 Correct 19 ms 23808 KB Output is correct
18 Correct 19 ms 23936 KB Output is correct
19 Correct 18 ms 23784 KB Output is correct
20 Correct 24 ms 23856 KB Output is correct
21 Correct 19 ms 23808 KB Output is correct
22 Correct 18 ms 23808 KB Output is correct
23 Correct 19 ms 23808 KB Output is correct
24 Correct 19 ms 23784 KB Output is correct
25 Correct 21 ms 23808 KB Output is correct
26 Correct 19 ms 23808 KB Output is correct
27 Correct 20 ms 23808 KB Output is correct
28 Correct 18 ms 23784 KB Output is correct
29 Correct 21 ms 23808 KB Output is correct
30 Correct 20 ms 23808 KB Output is correct
31 Correct 20 ms 23808 KB Output is correct
32 Correct 23 ms 23936 KB Output is correct
33 Correct 21 ms 23808 KB Output is correct
34 Correct 18 ms 23808 KB Output is correct
35 Correct 19 ms 23808 KB Output is correct
36 Correct 19 ms 23936 KB Output is correct
37 Correct 36 ms 23836 KB Output is correct
38 Correct 20 ms 23808 KB Output is correct
39 Correct 18 ms 23808 KB Output is correct
40 Correct 19 ms 23808 KB Output is correct
41 Correct 18 ms 23808 KB Output is correct
42 Correct 22 ms 23808 KB Output is correct
43 Correct 19 ms 23808 KB Output is correct
44 Correct 20 ms 23808 KB Output is correct
45 Correct 18 ms 23808 KB Output is correct
46 Correct 20 ms 23936 KB Output is correct
47 Correct 19 ms 23808 KB Output is correct
48 Correct 22 ms 23808 KB Output is correct
49 Correct 19 ms 23808 KB Output is correct
50 Correct 20 ms 23808 KB Output is correct
51 Correct 19 ms 23936 KB Output is correct
52 Correct 21 ms 23808 KB Output is correct
53 Correct 18 ms 23808 KB Output is correct
54 Correct 18 ms 23936 KB Output is correct
55 Correct 24 ms 23808 KB Output is correct
56 Correct 18 ms 23808 KB Output is correct
57 Correct 23 ms 23808 KB Output is correct
58 Correct 19 ms 23808 KB Output is correct
59 Correct 18 ms 23936 KB Output is correct
60 Correct 18 ms 23808 KB Output is correct
61 Correct 19 ms 23860 KB Output is correct
62 Correct 20 ms 23936 KB Output is correct
63 Correct 19 ms 23808 KB Output is correct
64 Correct 18 ms 23808 KB Output is correct
65 Correct 19 ms 23808 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 175 ms 45804 KB Output is correct
2 Correct 185 ms 45804 KB Output is correct
3 Correct 161 ms 48052 KB Output is correct
4 Correct 160 ms 47828 KB Output is correct
5 Correct 183 ms 46320 KB Output is correct
6 Correct 186 ms 49008 KB Output is correct
7 Correct 160 ms 48220 KB Output is correct
8 Correct 186 ms 48472 KB Output is correct
9 Correct 180 ms 47352 KB Output is correct
10 Correct 199 ms 46744 KB Output is correct
11 Correct 120 ms 44024 KB Output is correct
12 Correct 143 ms 43768 KB Output is correct
13 Correct 136 ms 43132 KB Output is correct
14 Correct 137 ms 42744 KB Output is correct
15 Correct 108 ms 40644 KB Output is correct
16 Correct 91 ms 40184 KB Output is correct
17 Correct 22 ms 28544 KB Output is correct
18 Correct 23 ms 28544 KB Output is correct
19 Correct 22 ms 28416 KB Output is correct
20 Correct 29 ms 28416 KB Output is correct
21 Correct 22 ms 28416 KB Output is correct
22 Correct 22 ms 28288 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 19 ms 24192 KB Output is correct
2 Correct 19 ms 24192 KB Output is correct
3 Correct 20 ms 24192 KB Output is correct
4 Correct 20 ms 24192 KB Output is correct
5 Correct 20 ms 24192 KB Output is correct
6 Correct 19 ms 24064 KB Output is correct
7 Correct 20 ms 24168 KB Output is correct
8 Correct 19 ms 24064 KB Output is correct
9 Correct 25 ms 24132 KB Output is correct
10 Correct 19 ms 24064 KB Output is correct
11 Correct 25 ms 24192 KB Output is correct
12 Correct 19 ms 24064 KB Output is correct
13 Correct 19 ms 24064 KB Output is correct
14 Correct 20 ms 24064 KB Output is correct
15 Correct 24 ms 24064 KB Output is correct
16 Correct 19 ms 23936 KB Output is correct
17 Correct 18 ms 24064 KB Output is correct
18 Correct 19 ms 24064 KB Output is correct
19 Correct 19 ms 24064 KB Output is correct
20 Correct 20 ms 24064 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 167 ms 50096 KB Output is correct
2 Correct 158 ms 51320 KB Output is correct
3 Correct 164 ms 51380 KB Output is correct
4 Correct 161 ms 51320 KB Output is correct
5 Correct 163 ms 51320 KB Output is correct
6 Correct 166 ms 55288 KB Output is correct
7 Correct 190 ms 54392 KB Output is correct
8 Correct 171 ms 53496 KB Output is correct
9 Correct 174 ms 52628 KB Output is correct
10 Correct 173 ms 51416 KB Output is correct
11 Correct 180 ms 51320 KB Output is correct
12 Correct 177 ms 51448 KB Output is correct
13 Correct 159 ms 51368 KB Output is correct
14 Correct 144 ms 49532 KB Output is correct
15 Correct 152 ms 47352 KB Output is correct
16 Correct 92 ms 41080 KB Output is correct
17 Correct 121 ms 51692 KB Output is correct
18 Correct 126 ms 51812 KB Output is correct
19 Correct 127 ms 52068 KB Output is correct
20 Correct 118 ms 51720 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 20 ms 24064 KB Output is correct
2 Correct 19 ms 24064 KB Output is correct
3 Correct 21 ms 24064 KB Output is correct
4 Correct 20 ms 24064 KB Output is correct
5 Correct 20 ms 24064 KB Output is correct
6 Correct 23 ms 24064 KB Output is correct
7 Correct 19 ms 24064 KB Output is correct
8 Correct 19 ms 24064 KB Output is correct
9 Correct 19 ms 24064 KB Output is correct
10 Correct 19 ms 24064 KB Output is correct
11 Correct 20 ms 24192 KB Output is correct
12 Correct 19 ms 24064 KB Output is correct
13 Correct 19 ms 24192 KB Output is correct
14 Correct 19 ms 24064 KB Output is correct
15 Correct 19 ms 24064 KB Output is correct
16 Correct 19 ms 24064 KB Output is correct
17 Correct 20 ms 24064 KB Output is correct
18 Correct 19 ms 24064 KB Output is correct
19 Correct 19 ms 24064 KB Output is correct
20 Correct 19 ms 24064 KB Output is correct
21 Correct 19 ms 24064 KB Output is correct
22 Correct 19 ms 24064 KB Output is correct
23 Correct 19 ms 24064 KB Output is correct
24 Correct 19 ms 24064 KB Output is correct
25 Correct 18 ms 23936 KB Output is correct
26 Correct 18 ms 23936 KB Output is correct
27 Correct 19 ms 23936 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 169 ms 50144 KB Output is correct
2 Correct 167 ms 51064 KB Output is correct
3 Correct 246 ms 49888 KB Output is correct
4 Correct 180 ms 47736 KB Output is correct
5 Correct 159 ms 44920 KB Output is correct
6 Correct 144 ms 43768 KB Output is correct
7 Correct 153 ms 43288 KB Output is correct
8 Correct 146 ms 42488 KB Output is correct
9 Correct 151 ms 42336 KB Output is correct
10 Correct 133 ms 42104 KB Output is correct
11 Correct 149 ms 41720 KB Output is correct
12 Correct 134 ms 41336 KB Output is correct
13 Correct 127 ms 41336 KB Output is correct
14 Correct 142 ms 42488 KB Output is correct
15 Correct 192 ms 53344 KB Output is correct
16 Correct 201 ms 52216 KB Output is correct
17 Correct 206 ms 51520 KB Output is correct
18 Correct 203 ms 50584 KB Output is correct
19 Correct 181 ms 47736 KB Output is correct
20 Correct 173 ms 47740 KB Output is correct
21 Correct 166 ms 47736 KB Output is correct
22 Correct 156 ms 45892 KB Output is correct
23 Correct 143 ms 43928 KB Output is correct
24 Correct 164 ms 49904 KB Output is correct
25 Correct 171 ms 50164 KB Output is correct
26 Correct 161 ms 48624 KB Output is correct
27 Correct 158 ms 48632 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 18 ms 23808 KB Output is correct
2 Correct 23 ms 23808 KB Output is correct
3 Correct 18 ms 23808 KB Output is correct
4 Correct 19 ms 23808 KB Output is correct
5 Correct 19 ms 23856 KB Output is correct
6 Correct 18 ms 23808 KB Output is correct
7 Correct 19 ms 23808 KB Output is correct
8 Correct 19 ms 23808 KB Output is correct
9 Correct 18 ms 23808 KB Output is correct
10 Correct 20 ms 23808 KB Output is correct
11 Correct 19 ms 23808 KB Output is correct
12 Correct 18 ms 23808 KB Output is correct
13 Correct 24 ms 23904 KB Output is correct
14 Correct 18 ms 23808 KB Output is correct
15 Correct 20 ms 23808 KB Output is correct
16 Correct 18 ms 23808 KB Output is correct
17 Correct 19 ms 23808 KB Output is correct
18 Correct 19 ms 23936 KB Output is correct
19 Correct 18 ms 23784 KB Output is correct
20 Correct 24 ms 23856 KB Output is correct
21 Correct 19 ms 23808 KB Output is correct
22 Correct 18 ms 23808 KB Output is correct
23 Correct 19 ms 23808 KB Output is correct
24 Correct 19 ms 23784 KB Output is correct
25 Correct 21 ms 23808 KB Output is correct
26 Correct 19 ms 23808 KB Output is correct
27 Correct 20 ms 23808 KB Output is correct
28 Correct 18 ms 23784 KB Output is correct
29 Correct 21 ms 23808 KB Output is correct
30 Correct 20 ms 23808 KB Output is correct
31 Correct 20 ms 23808 KB Output is correct
32 Correct 23 ms 23936 KB Output is correct
33 Correct 21 ms 23808 KB Output is correct
34 Correct 18 ms 23808 KB Output is correct
35 Correct 19 ms 23808 KB Output is correct
36 Correct 19 ms 23936 KB Output is correct
37 Correct 36 ms 23836 KB Output is correct
38 Correct 20 ms 23808 KB Output is correct
39 Correct 18 ms 23808 KB Output is correct
40 Correct 19 ms 23808 KB Output is correct
41 Correct 18 ms 23808 KB Output is correct
42 Correct 22 ms 23808 KB Output is correct
43 Correct 19 ms 23808 KB Output is correct
44 Correct 20 ms 23808 KB Output is correct
45 Correct 18 ms 23808 KB Output is correct
46 Correct 20 ms 23936 KB Output is correct
47 Correct 19 ms 23808 KB Output is correct
48 Correct 22 ms 23808 KB Output is correct
49 Correct 19 ms 23808 KB Output is correct
50 Correct 20 ms 23808 KB Output is correct
51 Correct 19 ms 23936 KB Output is correct
52 Correct 21 ms 23808 KB Output is correct
53 Correct 18 ms 23808 KB Output is correct
54 Correct 18 ms 23936 KB Output is correct
55 Correct 24 ms 23808 KB Output is correct
56 Correct 18 ms 23808 KB Output is correct
57 Correct 23 ms 23808 KB Output is correct
58 Correct 19 ms 23808 KB Output is correct
59 Correct 18 ms 23936 KB Output is correct
60 Correct 18 ms 23808 KB Output is correct
61 Correct 19 ms 23860 KB Output is correct
62 Correct 20 ms 23936 KB Output is correct
63 Correct 19 ms 23808 KB Output is correct
64 Correct 18 ms 23808 KB Output is correct
65 Correct 19 ms 23808 KB Output is correct
66 Correct 18 ms 23936 KB Output is correct
67 Correct 20 ms 24064 KB Output is correct
68 Correct 19 ms 24192 KB Output is correct
69 Correct 19 ms 24064 KB Output is correct
70 Correct 20 ms 24064 KB Output is correct
71 Correct 19 ms 24064 KB Output is correct
72 Correct 19 ms 24064 KB Output is correct
73 Correct 18 ms 24064 KB Output is correct
74 Correct 19 ms 24064 KB Output is correct
75 Correct 19 ms 24064 KB Output is correct
76 Correct 18 ms 23808 KB Output is correct
77 Correct 19 ms 24064 KB Output is correct
78 Correct 21 ms 24064 KB Output is correct
79 Correct 19 ms 24064 KB Output is correct
80 Correct 19 ms 24064 KB Output is correct
81 Correct 19 ms 24064 KB Output is correct
82 Correct 19 ms 24064 KB Output is correct
83 Correct 19 ms 24064 KB Output is correct
84 Correct 19 ms 24064 KB Output is correct
85 Correct 22 ms 24064 KB Output is correct
86 Correct 19 ms 24192 KB Output is correct
87 Correct 20 ms 24064 KB Output is correct
88 Correct 19 ms 24064 KB Output is correct
89 Correct 19 ms 24064 KB Output is correct
90 Correct 19 ms 24064 KB Output is correct
91 Correct 19 ms 24064 KB Output is correct
92 Correct 19 ms 24064 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 18 ms 23808 KB Output is correct
2 Correct 23 ms 23808 KB Output is correct
3 Correct 18 ms 23808 KB Output is correct
4 Correct 19 ms 23808 KB Output is correct
5 Correct 19 ms 23856 KB Output is correct
6 Correct 18 ms 23808 KB Output is correct
7 Correct 19 ms 23808 KB Output is correct
8 Correct 19 ms 23808 KB Output is correct
9 Correct 18 ms 23808 KB Output is correct
10 Correct 20 ms 23808 KB Output is correct
11 Correct 19 ms 23808 KB Output is correct
12 Correct 18 ms 23808 KB Output is correct
13 Correct 24 ms 23904 KB Output is correct
14 Correct 18 ms 23808 KB Output is correct
15 Correct 20 ms 23808 KB Output is correct
16 Correct 18 ms 23808 KB Output is correct
17 Correct 19 ms 23808 KB Output is correct
18 Correct 19 ms 23936 KB Output is correct
19 Correct 18 ms 23784 KB Output is correct
20 Correct 24 ms 23856 KB Output is correct
21 Correct 19 ms 23808 KB Output is correct
22 Correct 18 ms 23808 KB Output is correct
23 Correct 19 ms 23808 KB Output is correct
24 Correct 19 ms 23784 KB Output is correct
25 Correct 21 ms 23808 KB Output is correct
26 Correct 19 ms 23808 KB Output is correct
27 Correct 20 ms 23808 KB Output is correct
28 Correct 18 ms 23784 KB Output is correct
29 Correct 21 ms 23808 KB Output is correct
30 Correct 20 ms 23808 KB Output is correct
31 Correct 20 ms 23808 KB Output is correct
32 Correct 23 ms 23936 KB Output is correct
33 Correct 21 ms 23808 KB Output is correct
34 Correct 18 ms 23808 KB Output is correct
35 Correct 19 ms 23808 KB Output is correct
36 Correct 19 ms 23936 KB Output is correct
37 Correct 36 ms 23836 KB Output is correct
38 Correct 20 ms 23808 KB Output is correct
39 Correct 18 ms 23808 KB Output is correct
40 Correct 19 ms 23808 KB Output is correct
41 Correct 18 ms 23808 KB Output is correct
42 Correct 22 ms 23808 KB Output is correct
43 Correct 19 ms 23808 KB Output is correct
44 Correct 20 ms 23808 KB Output is correct
45 Correct 18 ms 23808 KB Output is correct
46 Correct 20 ms 23936 KB Output is correct
47 Correct 19 ms 23808 KB Output is correct
48 Correct 22 ms 23808 KB Output is correct
49 Correct 19 ms 23808 KB Output is correct
50 Correct 20 ms 23808 KB Output is correct
51 Correct 19 ms 23936 KB Output is correct
52 Correct 21 ms 23808 KB Output is correct
53 Correct 18 ms 23808 KB Output is correct
54 Correct 18 ms 23936 KB Output is correct
55 Correct 24 ms 23808 KB Output is correct
56 Correct 18 ms 23808 KB Output is correct
57 Correct 23 ms 23808 KB Output is correct
58 Correct 19 ms 23808 KB Output is correct
59 Correct 18 ms 23936 KB Output is correct
60 Correct 18 ms 23808 KB Output is correct
61 Correct 19 ms 23860 KB Output is correct
62 Correct 20 ms 23936 KB Output is correct
63 Correct 19 ms 23808 KB Output is correct
64 Correct 18 ms 23808 KB Output is correct
65 Correct 19 ms 23808 KB Output is correct
66 Correct 175 ms 45804 KB Output is correct
67 Correct 185 ms 45804 KB Output is correct
68 Correct 161 ms 48052 KB Output is correct
69 Correct 160 ms 47828 KB Output is correct
70 Correct 183 ms 46320 KB Output is correct
71 Correct 186 ms 49008 KB Output is correct
72 Correct 160 ms 48220 KB Output is correct
73 Correct 186 ms 48472 KB Output is correct
74 Correct 180 ms 47352 KB Output is correct
75 Correct 199 ms 46744 KB Output is correct
76 Correct 120 ms 44024 KB Output is correct
77 Correct 143 ms 43768 KB Output is correct
78 Correct 136 ms 43132 KB Output is correct
79 Correct 137 ms 42744 KB Output is correct
80 Correct 108 ms 40644 KB Output is correct
81 Correct 91 ms 40184 KB Output is correct
82 Correct 22 ms 28544 KB Output is correct
83 Correct 23 ms 28544 KB Output is correct
84 Correct 22 ms 28416 KB Output is correct
85 Correct 29 ms 28416 KB Output is correct
86 Correct 22 ms 28416 KB Output is correct
87 Correct 22 ms 28288 KB Output is correct
88 Correct 19 ms 24192 KB Output is correct
89 Correct 19 ms 24192 KB Output is correct
90 Correct 20 ms 24192 KB Output is correct
91 Correct 20 ms 24192 KB Output is correct
92 Correct 20 ms 24192 KB Output is correct
93 Correct 19 ms 24064 KB Output is correct
94 Correct 20 ms 24168 KB Output is correct
95 Correct 19 ms 24064 KB Output is correct
96 Correct 25 ms 24132 KB Output is correct
97 Correct 19 ms 24064 KB Output is correct
98 Correct 25 ms 24192 KB Output is correct
99 Correct 19 ms 24064 KB Output is correct
100 Correct 19 ms 24064 KB Output is correct
101 Correct 20 ms 24064 KB Output is correct
102 Correct 24 ms 24064 KB Output is correct
103 Correct 19 ms 23936 KB Output is correct
104 Correct 18 ms 24064 KB Output is correct
105 Correct 19 ms 24064 KB Output is correct
106 Correct 19 ms 24064 KB Output is correct
107 Correct 20 ms 24064 KB Output is correct
108 Correct 167 ms 50096 KB Output is correct
109 Correct 158 ms 51320 KB Output is correct
110 Correct 164 ms 51380 KB Output is correct
111 Correct 161 ms 51320 KB Output is correct
112 Correct 163 ms 51320 KB Output is correct
113 Correct 166 ms 55288 KB Output is correct
114 Correct 190 ms 54392 KB Output is correct
115 Correct 171 ms 53496 KB Output is correct
116 Correct 174 ms 52628 KB Output is correct
117 Correct 173 ms 51416 KB Output is correct
118 Correct 180 ms 51320 KB Output is correct
119 Correct 177 ms 51448 KB Output is correct
120 Correct 159 ms 51368 KB Output is correct
121 Correct 144 ms 49532 KB Output is correct
122 Correct 152 ms 47352 KB Output is correct
123 Correct 92 ms 41080 KB Output is correct
124 Correct 121 ms 51692 KB Output is correct
125 Correct 126 ms 51812 KB Output is correct
126 Correct 127 ms 52068 KB Output is correct
127 Correct 118 ms 51720 KB Output is correct
128 Correct 20 ms 24064 KB Output is correct
129 Correct 19 ms 24064 KB Output is correct
130 Correct 21 ms 24064 KB Output is correct
131 Correct 20 ms 24064 KB Output is correct
132 Correct 20 ms 24064 KB Output is correct
133 Correct 23 ms 24064 KB Output is correct
134 Correct 19 ms 24064 KB Output is correct
135 Correct 19 ms 24064 KB Output is correct
136 Correct 19 ms 24064 KB Output is correct
137 Correct 19 ms 24064 KB Output is correct
138 Correct 20 ms 24192 KB Output is correct
139 Correct 19 ms 24064 KB Output is correct
140 Correct 19 ms 24192 KB Output is correct
141 Correct 19 ms 24064 KB Output is correct
142 Correct 19 ms 24064 KB Output is correct
143 Correct 19 ms 24064 KB Output is correct
144 Correct 20 ms 24064 KB Output is correct
145 Correct 19 ms 24064 KB Output is correct
146 Correct 19 ms 24064 KB Output is correct
147 Correct 19 ms 24064 KB Output is correct
148 Correct 19 ms 24064 KB Output is correct
149 Correct 19 ms 24064 KB Output is correct
150 Correct 19 ms 24064 KB Output is correct
151 Correct 19 ms 24064 KB Output is correct
152 Correct 18 ms 23936 KB Output is correct
153 Correct 18 ms 23936 KB Output is correct
154 Correct 19 ms 23936 KB Output is correct
155 Correct 169 ms 50144 KB Output is correct
156 Correct 167 ms 51064 KB Output is correct
157 Correct 246 ms 49888 KB Output is correct
158 Correct 180 ms 47736 KB Output is correct
159 Correct 159 ms 44920 KB Output is correct
160 Correct 144 ms 43768 KB Output is correct
161 Correct 153 ms 43288 KB Output is correct
162 Correct 146 ms 42488 KB Output is correct
163 Correct 151 ms 42336 KB Output is correct
164 Correct 133 ms 42104 KB Output is correct
165 Correct 149 ms 41720 KB Output is correct
166 Correct 134 ms 41336 KB Output is correct
167 Correct 127 ms 41336 KB Output is correct
168 Correct 142 ms 42488 KB Output is correct
169 Correct 192 ms 53344 KB Output is correct
170 Correct 201 ms 52216 KB Output is correct
171 Correct 206 ms 51520 KB Output is correct
172 Correct 203 ms 50584 KB Output is correct
173 Correct 181 ms 47736 KB Output is correct
174 Correct 173 ms 47740 KB Output is correct
175 Correct 166 ms 47736 KB Output is correct
176 Correct 156 ms 45892 KB Output is correct
177 Correct 143 ms 43928 KB Output is correct
178 Correct 164 ms 49904 KB Output is correct
179 Correct 171 ms 50164 KB Output is correct
180 Correct 161 ms 48624 KB Output is correct
181 Correct 158 ms 48632 KB Output is correct
182 Correct 18 ms 23936 KB Output is correct
183 Correct 20 ms 24064 KB Output is correct
184 Correct 19 ms 24192 KB Output is correct
185 Correct 19 ms 24064 KB Output is correct
186 Correct 20 ms 24064 KB Output is correct
187 Correct 19 ms 24064 KB Output is correct
188 Correct 19 ms 24064 KB Output is correct
189 Correct 18 ms 24064 KB Output is correct
190 Correct 19 ms 24064 KB Output is correct
191 Correct 19 ms 24064 KB Output is correct
192 Correct 18 ms 23808 KB Output is correct
193 Correct 19 ms 24064 KB Output is correct
194 Correct 21 ms 24064 KB Output is correct
195 Correct 19 ms 24064 KB Output is correct
196 Correct 19 ms 24064 KB Output is correct
197 Correct 19 ms 24064 KB Output is correct
198 Correct 19 ms 24064 KB Output is correct
199 Correct 19 ms 24064 KB Output is correct
200 Correct 19 ms 24064 KB Output is correct
201 Correct 22 ms 24064 KB Output is correct
202 Correct 19 ms 24192 KB Output is correct
203 Correct 20 ms 24064 KB Output is correct
204 Correct 19 ms 24064 KB Output is correct
205 Correct 19 ms 24064 KB Output is correct
206 Correct 19 ms 24064 KB Output is correct
207 Correct 19 ms 24064 KB Output is correct
208 Correct 19 ms 24064 KB Output is correct
209 Correct 22 ms 27776 KB Output is correct
210 Correct 93 ms 40440 KB Output is correct
211 Correct 151 ms 45040 KB Output is correct
212 Correct 206 ms 47060 KB Output is correct
213 Correct 222 ms 48876 KB Output is correct
214 Correct 96 ms 44408 KB Output is correct
215 Correct 101 ms 43644 KB Output is correct
216 Correct 163 ms 49144 KB Output is correct
217 Correct 175 ms 46072 KB Output is correct
218 Correct 142 ms 42744 KB Output is correct
219 Correct 140 ms 41992 KB Output is correct
220 Correct 134 ms 41848 KB Output is correct
221 Correct 136 ms 41208 KB Output is correct
222 Correct 159 ms 41848 KB Output is correct
223 Correct 191 ms 47736 KB Output is correct
224 Correct 185 ms 47352 KB Output is correct
225 Correct 160 ms 45432 KB Output is correct
226 Correct 174 ms 45604 KB Output is correct
227 Correct 154 ms 45432 KB Output is correct
228 Correct 158 ms 44024 KB Output is correct
229 Correct 125 ms 42748 KB Output is correct
230 Correct 156 ms 46184 KB Output is correct
231 Correct 154 ms 46148 KB Output is correct