답안 #1114765

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
1114765 2024-11-19T14:43:57 Z asli_bg 철인 이종 경기 (APIO18_duathlon) C++11
100 / 100
87 ms 48064 KB
#include <bits/stdc++.h>
using namespace std;

#define int long long

#define fi first
#define se second
#define all(x) x.begin(),x.end()
#define sp <<' '<<
#define pb push_back

#define FOR(i,a) for(int i=0;i<(a);i++)
#define FORE(i,a,b) for(int i=(a);i<(b);i++)

#define cont(a) for(auto el:a) cout<<el<<' '; cout<<endl;
#define contp(a) for(auto el:a) cout<<el.fi<<'-'<<el.se<<' ';cout<<endl;

#define DEBUG(x) cout<<#x sp ":" sp x<<endl;

typedef vector<int> vi;
typedef pair<int,int> pii;
typedef vector<pii> vii;
typedef long long ll;

#define endl '\n'
#define mid (l+r)/2

const int MAXN=4e5+5;

int n,m;
vi adj[MAXN];
int ans;

/*----------BLOCK-CUT TREE----------- */

bool vis[MAXN], isarc[MAXN];
int dep[MAXN], low[MAXN];

vi st;

vi bcc[MAXN];

int cnt; //şuanki grafta kaç eleman var

int ind;

void dfs(int nd, int ata,int h){
    dep[nd]=h;
    low[nd]=h;

    int ch=0;
    st.pb(nd);

    cnt++;

    for(auto kom:adj[nd]){
        if(kom==ata) continue;
        if(vis[kom]){
            if(dep[kom]<dep[nd]) low[nd]=min(low[nd],dep[kom]);
            continue;
        }

        vis[kom]=true;
        dfs(kom,nd,h+1);
        
        ch++;

        if(low[kom]>=dep[nd]){ //we should create new block
            //komsuyu tüm graftan ayıran node == nd

            ind++;
            bcc[nd].pb(ind); //nodedan yeni bloğa

            int el;  
            do{
                el=st.back();
                st.pop_back();
                bcc[ind].pb(el);
            }while(el!=kom); //bloktan elemanlara edge çek

            if(ata!=-1) isarc[nd]=true;
        }

        low[nd]=min(low[nd],low[kom]);
    }

    if(ata==-1 and ch>1) isarc[nd]=true; 
}

/*----------DFS----------- */

int sub[MAXN];
bool vis2[MAXN];

void dfs2(int nd,int ata){

    sub[nd]=(nd<=n); //ben blok muyum yoksa node muyum

    for(auto kom:bcc[nd]){
        if(kom==ata) continue;
        if(vis2[kom]) continue;

        vis2[kom]=true;
        dfs2(kom,nd);
        sub[nd]+=sub[kom];

        if(nd>n){
            //ben bloksam
            //bcc[nd].size() --> bende kaç eleman var
            int bir=bcc[nd].size(); //bu bloktan 1 tane
            int iki=sub[kom]*(sub[kom]-1); //subtreemdeki nodelardan 2 tane seç

            ans-=max(0LL,bir*iki);
        }
    }

    //beni root kabul edip hesaplama yapıyorum
    //benim üstümde kalan subtreeyi hesaplamadık

    if(nd>n){
        int bir=bcc[nd].size();
        int iki=(cnt-sub[nd])*(cnt-sub[nd]-1);
        ans-=bir*iki;
    }
}

signed main(){
    ios_base::sync_with_stdio(0);
    cin.tie(0);

    cin>>n>>m;
    FOR(i,m){
        int a,b;
        cin>>a>>b;
        adj[a].pb(b);
        adj[b].pb(a);
    }

    ind=n;

    FORE(j,1,n+1){
        if(!vis[j]){
            cnt=0;
            st.clear();

            vis[j]=true;

            dfs(j,-1,0);

            ans+=(cnt)*(cnt-1)*(cnt-2);

            dfs2(j,-1);
        }
    }

    cout<<ans<<endl;
}
# 결과 실행 시간 메모리 Grader output
1 Correct 5 ms 27472 KB Output is correct
2 Correct 5 ms 27472 KB Output is correct
3 Correct 5 ms 27472 KB Output is correct
4 Correct 5 ms 27472 KB Output is correct
5 Correct 5 ms 27488 KB Output is correct
6 Correct 6 ms 27472 KB Output is correct
7 Correct 5 ms 27640 KB Output is correct
8 Correct 5 ms 27640 KB Output is correct
9 Correct 5 ms 27472 KB Output is correct
10 Correct 5 ms 27472 KB Output is correct
11 Correct 5 ms 27472 KB Output is correct
12 Correct 5 ms 27472 KB Output is correct
13 Correct 5 ms 27584 KB Output is correct
14 Correct 5 ms 27640 KB Output is correct
15 Correct 5 ms 27472 KB Output is correct
16 Correct 4 ms 27472 KB Output is correct
17 Correct 5 ms 27472 KB Output is correct
18 Correct 5 ms 27472 KB Output is correct
19 Correct 5 ms 27472 KB Output is correct
20 Correct 5 ms 27472 KB Output is correct
21 Correct 6 ms 27472 KB Output is correct
22 Correct 5 ms 27472 KB Output is correct
23 Correct 5 ms 27472 KB Output is correct
24 Correct 5 ms 27576 KB Output is correct
25 Correct 5 ms 27472 KB Output is correct
26 Correct 6 ms 27472 KB Output is correct
27 Correct 6 ms 27640 KB Output is correct
28 Correct 5 ms 27336 KB Output is correct
29 Correct 5 ms 27472 KB Output is correct
30 Correct 5 ms 27472 KB Output is correct
31 Correct 4 ms 27568 KB Output is correct
32 Correct 4 ms 27640 KB Output is correct
33 Correct 4 ms 27472 KB Output is correct
34 Correct 4 ms 27472 KB Output is correct
35 Correct 4 ms 27472 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 5 ms 27472 KB Output is correct
2 Correct 5 ms 27472 KB Output is correct
3 Correct 5 ms 27472 KB Output is correct
4 Correct 5 ms 27472 KB Output is correct
5 Correct 5 ms 27488 KB Output is correct
6 Correct 6 ms 27472 KB Output is correct
7 Correct 5 ms 27640 KB Output is correct
8 Correct 5 ms 27640 KB Output is correct
9 Correct 5 ms 27472 KB Output is correct
10 Correct 5 ms 27472 KB Output is correct
11 Correct 5 ms 27472 KB Output is correct
12 Correct 5 ms 27472 KB Output is correct
13 Correct 5 ms 27584 KB Output is correct
14 Correct 5 ms 27640 KB Output is correct
15 Correct 5 ms 27472 KB Output is correct
16 Correct 4 ms 27472 KB Output is correct
17 Correct 5 ms 27472 KB Output is correct
18 Correct 5 ms 27472 KB Output is correct
19 Correct 5 ms 27472 KB Output is correct
20 Correct 5 ms 27472 KB Output is correct
21 Correct 6 ms 27472 KB Output is correct
22 Correct 5 ms 27472 KB Output is correct
23 Correct 5 ms 27472 KB Output is correct
24 Correct 5 ms 27576 KB Output is correct
25 Correct 5 ms 27472 KB Output is correct
26 Correct 6 ms 27472 KB Output is correct
27 Correct 6 ms 27640 KB Output is correct
28 Correct 5 ms 27336 KB Output is correct
29 Correct 5 ms 27472 KB Output is correct
30 Correct 5 ms 27472 KB Output is correct
31 Correct 4 ms 27568 KB Output is correct
32 Correct 4 ms 27640 KB Output is correct
33 Correct 4 ms 27472 KB Output is correct
34 Correct 4 ms 27472 KB Output is correct
35 Correct 4 ms 27472 KB Output is correct
36 Correct 5 ms 27472 KB Output is correct
37 Correct 5 ms 27472 KB Output is correct
38 Correct 4 ms 27472 KB Output is correct
39 Correct 5 ms 27472 KB Output is correct
40 Correct 5 ms 27472 KB Output is correct
41 Correct 5 ms 27544 KB Output is correct
42 Correct 5 ms 27472 KB Output is correct
43 Correct 5 ms 27472 KB Output is correct
44 Correct 5 ms 27472 KB Output is correct
45 Correct 4 ms 27472 KB Output is correct
46 Correct 5 ms 27472 KB Output is correct
47 Correct 5 ms 27472 KB Output is correct
48 Correct 5 ms 27472 KB Output is correct
49 Correct 5 ms 27472 KB Output is correct
50 Correct 4 ms 27472 KB Output is correct
51 Correct 4 ms 27472 KB Output is correct
52 Correct 4 ms 27592 KB Output is correct
53 Correct 4 ms 27472 KB Output is correct
54 Correct 4 ms 27472 KB Output is correct
55 Correct 4 ms 27472 KB Output is correct
56 Correct 4 ms 27592 KB Output is correct
57 Correct 4 ms 27472 KB Output is correct
58 Correct 5 ms 27472 KB Output is correct
59 Correct 5 ms 27472 KB Output is correct
60 Correct 6 ms 27472 KB Output is correct
61 Correct 5 ms 27472 KB Output is correct
62 Correct 5 ms 27472 KB Output is correct
63 Correct 5 ms 27588 KB Output is correct
64 Correct 5 ms 27472 KB Output is correct
65 Correct 5 ms 27472 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 47 ms 45376 KB Output is correct
2 Correct 49 ms 45376 KB Output is correct
3 Correct 56 ms 43084 KB Output is correct
4 Correct 51 ms 44748 KB Output is correct
5 Correct 51 ms 39880 KB Output is correct
6 Correct 58 ms 42308 KB Output is correct
7 Correct 75 ms 40380 KB Output is correct
8 Correct 59 ms 40900 KB Output is correct
9 Correct 52 ms 38476 KB Output is correct
10 Correct 57 ms 38596 KB Output is correct
11 Correct 46 ms 35920 KB Output is correct
12 Correct 47 ms 35692 KB Output is correct
13 Correct 37 ms 35628 KB Output is correct
14 Correct 39 ms 35352 KB Output is correct
15 Correct 32 ms 34636 KB Output is correct
16 Correct 28 ms 34640 KB Output is correct
17 Correct 7 ms 29520 KB Output is correct
18 Correct 6 ms 29520 KB Output is correct
19 Correct 7 ms 29520 KB Output is correct
20 Correct 6 ms 29584 KB Output is correct
21 Correct 6 ms 29520 KB Output is correct
22 Correct 6 ms 29520 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 5 ms 27472 KB Output is correct
2 Correct 5 ms 27472 KB Output is correct
3 Correct 7 ms 27472 KB Output is correct
4 Correct 6 ms 27728 KB Output is correct
5 Correct 5 ms 27728 KB Output is correct
6 Correct 5 ms 27896 KB Output is correct
7 Correct 6 ms 27728 KB Output is correct
8 Correct 5 ms 27728 KB Output is correct
9 Correct 5 ms 27704 KB Output is correct
10 Correct 5 ms 27668 KB Output is correct
11 Correct 5 ms 27484 KB Output is correct
12 Correct 5 ms 27472 KB Output is correct
13 Correct 6 ms 27536 KB Output is correct
14 Correct 5 ms 27472 KB Output is correct
15 Correct 6 ms 27472 KB Output is correct
16 Correct 5 ms 27472 KB Output is correct
17 Correct 5 ms 27472 KB Output is correct
18 Correct 5 ms 27640 KB Output is correct
19 Correct 5 ms 27472 KB Output is correct
20 Correct 5 ms 27472 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 56 ms 38488 KB Output is correct
2 Correct 54 ms 38472 KB Output is correct
3 Correct 52 ms 38504 KB Output is correct
4 Correct 71 ms 38472 KB Output is correct
5 Correct 56 ms 38472 KB Output is correct
6 Correct 59 ms 48064 KB Output is correct
7 Correct 61 ms 44676 KB Output is correct
8 Correct 62 ms 43208 KB Output is correct
9 Correct 69 ms 41552 KB Output is correct
10 Correct 51 ms 38516 KB Output is correct
11 Correct 51 ms 38472 KB Output is correct
12 Correct 49 ms 38472 KB Output is correct
13 Correct 50 ms 38476 KB Output is correct
14 Correct 44 ms 37968 KB Output is correct
15 Correct 42 ms 37124 KB Output is correct
16 Correct 30 ms 35028 KB Output is correct
17 Correct 36 ms 37572 KB Output is correct
18 Correct 50 ms 37516 KB Output is correct
19 Correct 40 ms 37844 KB Output is correct
20 Correct 49 ms 37440 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 5 ms 27472 KB Output is correct
2 Correct 5 ms 27472 KB Output is correct
3 Correct 5 ms 27472 KB Output is correct
4 Correct 5 ms 27472 KB Output is correct
5 Correct 6 ms 27472 KB Output is correct
6 Correct 5 ms 27640 KB Output is correct
7 Correct 6 ms 27472 KB Output is correct
8 Correct 6 ms 27472 KB Output is correct
9 Correct 6 ms 27640 KB Output is correct
10 Correct 5 ms 27472 KB Output is correct
11 Correct 6 ms 27480 KB Output is correct
12 Correct 6 ms 27728 KB Output is correct
13 Correct 6 ms 27472 KB Output is correct
14 Correct 6 ms 27728 KB Output is correct
15 Correct 6 ms 27472 KB Output is correct
16 Correct 5 ms 27660 KB Output is correct
17 Correct 5 ms 27472 KB Output is correct
18 Correct 5 ms 27472 KB Output is correct
19 Correct 5 ms 27472 KB Output is correct
20 Correct 5 ms 27472 KB Output is correct
21 Correct 5 ms 27472 KB Output is correct
22 Correct 5 ms 27472 KB Output is correct
23 Correct 5 ms 27472 KB Output is correct
24 Correct 5 ms 27472 KB Output is correct
25 Correct 5 ms 27472 KB Output is correct
26 Correct 4 ms 27472 KB Output is correct
27 Correct 5 ms 27644 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 54 ms 38472 KB Output is correct
2 Correct 55 ms 38472 KB Output is correct
3 Correct 59 ms 37996 KB Output is correct
4 Correct 57 ms 37032 KB Output is correct
5 Correct 54 ms 35912 KB Output is correct
6 Correct 41 ms 35144 KB Output is correct
7 Correct 40 ms 34888 KB Output is correct
8 Correct 37 ms 34480 KB Output is correct
9 Correct 38 ms 34520 KB Output is correct
10 Correct 38 ms 34452 KB Output is correct
11 Correct 45 ms 34120 KB Output is correct
12 Correct 42 ms 34124 KB Output is correct
13 Correct 37 ms 34400 KB Output is correct
14 Correct 43 ms 37056 KB Output is correct
15 Correct 79 ms 44492 KB Output is correct
16 Correct 82 ms 42220 KB Output is correct
17 Correct 86 ms 42944 KB Output is correct
18 Correct 65 ms 41148 KB Output is correct
19 Correct 49 ms 36936 KB Output is correct
20 Correct 59 ms 36944 KB Output is correct
21 Correct 70 ms 36928 KB Output is correct
22 Correct 48 ms 36604 KB Output is correct
23 Correct 44 ms 35660 KB Output is correct
24 Correct 57 ms 37440 KB Output is correct
25 Correct 63 ms 37620 KB Output is correct
26 Correct 57 ms 36956 KB Output is correct
27 Correct 50 ms 37104 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 5 ms 27472 KB Output is correct
2 Correct 5 ms 27472 KB Output is correct
3 Correct 5 ms 27472 KB Output is correct
4 Correct 5 ms 27472 KB Output is correct
5 Correct 5 ms 27488 KB Output is correct
6 Correct 6 ms 27472 KB Output is correct
7 Correct 5 ms 27640 KB Output is correct
8 Correct 5 ms 27640 KB Output is correct
9 Correct 5 ms 27472 KB Output is correct
10 Correct 5 ms 27472 KB Output is correct
11 Correct 5 ms 27472 KB Output is correct
12 Correct 5 ms 27472 KB Output is correct
13 Correct 5 ms 27584 KB Output is correct
14 Correct 5 ms 27640 KB Output is correct
15 Correct 5 ms 27472 KB Output is correct
16 Correct 4 ms 27472 KB Output is correct
17 Correct 5 ms 27472 KB Output is correct
18 Correct 5 ms 27472 KB Output is correct
19 Correct 5 ms 27472 KB Output is correct
20 Correct 5 ms 27472 KB Output is correct
21 Correct 6 ms 27472 KB Output is correct
22 Correct 5 ms 27472 KB Output is correct
23 Correct 5 ms 27472 KB Output is correct
24 Correct 5 ms 27576 KB Output is correct
25 Correct 5 ms 27472 KB Output is correct
26 Correct 6 ms 27472 KB Output is correct
27 Correct 6 ms 27640 KB Output is correct
28 Correct 5 ms 27336 KB Output is correct
29 Correct 5 ms 27472 KB Output is correct
30 Correct 5 ms 27472 KB Output is correct
31 Correct 4 ms 27568 KB Output is correct
32 Correct 4 ms 27640 KB Output is correct
33 Correct 4 ms 27472 KB Output is correct
34 Correct 4 ms 27472 KB Output is correct
35 Correct 4 ms 27472 KB Output is correct
36 Correct 5 ms 27472 KB Output is correct
37 Correct 5 ms 27472 KB Output is correct
38 Correct 4 ms 27472 KB Output is correct
39 Correct 5 ms 27472 KB Output is correct
40 Correct 5 ms 27472 KB Output is correct
41 Correct 5 ms 27544 KB Output is correct
42 Correct 5 ms 27472 KB Output is correct
43 Correct 5 ms 27472 KB Output is correct
44 Correct 5 ms 27472 KB Output is correct
45 Correct 4 ms 27472 KB Output is correct
46 Correct 5 ms 27472 KB Output is correct
47 Correct 5 ms 27472 KB Output is correct
48 Correct 5 ms 27472 KB Output is correct
49 Correct 5 ms 27472 KB Output is correct
50 Correct 4 ms 27472 KB Output is correct
51 Correct 4 ms 27472 KB Output is correct
52 Correct 4 ms 27592 KB Output is correct
53 Correct 4 ms 27472 KB Output is correct
54 Correct 4 ms 27472 KB Output is correct
55 Correct 4 ms 27472 KB Output is correct
56 Correct 4 ms 27592 KB Output is correct
57 Correct 4 ms 27472 KB Output is correct
58 Correct 5 ms 27472 KB Output is correct
59 Correct 5 ms 27472 KB Output is correct
60 Correct 6 ms 27472 KB Output is correct
61 Correct 5 ms 27472 KB Output is correct
62 Correct 5 ms 27472 KB Output is correct
63 Correct 5 ms 27588 KB Output is correct
64 Correct 5 ms 27472 KB Output is correct
65 Correct 5 ms 27472 KB Output is correct
66 Correct 5 ms 27472 KB Output is correct
67 Correct 5 ms 27484 KB Output is correct
68 Correct 5 ms 27472 KB Output is correct
69 Correct 6 ms 27716 KB Output is correct
70 Correct 5 ms 27892 KB Output is correct
71 Correct 5 ms 27472 KB Output is correct
72 Correct 5 ms 27472 KB Output is correct
73 Correct 5 ms 27472 KB Output is correct
74 Correct 5 ms 27472 KB Output is correct
75 Correct 5 ms 27472 KB Output is correct
76 Correct 6 ms 27544 KB Output is correct
77 Correct 6 ms 27472 KB Output is correct
78 Correct 5 ms 27472 KB Output is correct
79 Correct 5 ms 27472 KB Output is correct
80 Correct 5 ms 27472 KB Output is correct
81 Correct 6 ms 27472 KB Output is correct
82 Correct 6 ms 27472 KB Output is correct
83 Correct 5 ms 27728 KB Output is correct
84 Correct 7 ms 27472 KB Output is correct
85 Correct 6 ms 27580 KB Output is correct
86 Correct 6 ms 27472 KB Output is correct
87 Correct 7 ms 27472 KB Output is correct
88 Correct 5 ms 27472 KB Output is correct
89 Correct 5 ms 27472 KB Output is correct
90 Correct 5 ms 27472 KB Output is correct
91 Correct 5 ms 27484 KB Output is correct
92 Correct 5 ms 27472 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 5 ms 27472 KB Output is correct
2 Correct 5 ms 27472 KB Output is correct
3 Correct 5 ms 27472 KB Output is correct
4 Correct 5 ms 27472 KB Output is correct
5 Correct 5 ms 27488 KB Output is correct
6 Correct 6 ms 27472 KB Output is correct
7 Correct 5 ms 27640 KB Output is correct
8 Correct 5 ms 27640 KB Output is correct
9 Correct 5 ms 27472 KB Output is correct
10 Correct 5 ms 27472 KB Output is correct
11 Correct 5 ms 27472 KB Output is correct
12 Correct 5 ms 27472 KB Output is correct
13 Correct 5 ms 27584 KB Output is correct
14 Correct 5 ms 27640 KB Output is correct
15 Correct 5 ms 27472 KB Output is correct
16 Correct 4 ms 27472 KB Output is correct
17 Correct 5 ms 27472 KB Output is correct
18 Correct 5 ms 27472 KB Output is correct
19 Correct 5 ms 27472 KB Output is correct
20 Correct 5 ms 27472 KB Output is correct
21 Correct 6 ms 27472 KB Output is correct
22 Correct 5 ms 27472 KB Output is correct
23 Correct 5 ms 27472 KB Output is correct
24 Correct 5 ms 27576 KB Output is correct
25 Correct 5 ms 27472 KB Output is correct
26 Correct 6 ms 27472 KB Output is correct
27 Correct 6 ms 27640 KB Output is correct
28 Correct 5 ms 27336 KB Output is correct
29 Correct 5 ms 27472 KB Output is correct
30 Correct 5 ms 27472 KB Output is correct
31 Correct 4 ms 27568 KB Output is correct
32 Correct 4 ms 27640 KB Output is correct
33 Correct 4 ms 27472 KB Output is correct
34 Correct 4 ms 27472 KB Output is correct
35 Correct 4 ms 27472 KB Output is correct
36 Correct 5 ms 27472 KB Output is correct
37 Correct 5 ms 27472 KB Output is correct
38 Correct 4 ms 27472 KB Output is correct
39 Correct 5 ms 27472 KB Output is correct
40 Correct 5 ms 27472 KB Output is correct
41 Correct 5 ms 27544 KB Output is correct
42 Correct 5 ms 27472 KB Output is correct
43 Correct 5 ms 27472 KB Output is correct
44 Correct 5 ms 27472 KB Output is correct
45 Correct 4 ms 27472 KB Output is correct
46 Correct 5 ms 27472 KB Output is correct
47 Correct 5 ms 27472 KB Output is correct
48 Correct 5 ms 27472 KB Output is correct
49 Correct 5 ms 27472 KB Output is correct
50 Correct 4 ms 27472 KB Output is correct
51 Correct 4 ms 27472 KB Output is correct
52 Correct 4 ms 27592 KB Output is correct
53 Correct 4 ms 27472 KB Output is correct
54 Correct 4 ms 27472 KB Output is correct
55 Correct 4 ms 27472 KB Output is correct
56 Correct 4 ms 27592 KB Output is correct
57 Correct 4 ms 27472 KB Output is correct
58 Correct 5 ms 27472 KB Output is correct
59 Correct 5 ms 27472 KB Output is correct
60 Correct 6 ms 27472 KB Output is correct
61 Correct 5 ms 27472 KB Output is correct
62 Correct 5 ms 27472 KB Output is correct
63 Correct 5 ms 27588 KB Output is correct
64 Correct 5 ms 27472 KB Output is correct
65 Correct 5 ms 27472 KB Output is correct
66 Correct 47 ms 45376 KB Output is correct
67 Correct 49 ms 45376 KB Output is correct
68 Correct 56 ms 43084 KB Output is correct
69 Correct 51 ms 44748 KB Output is correct
70 Correct 51 ms 39880 KB Output is correct
71 Correct 58 ms 42308 KB Output is correct
72 Correct 75 ms 40380 KB Output is correct
73 Correct 59 ms 40900 KB Output is correct
74 Correct 52 ms 38476 KB Output is correct
75 Correct 57 ms 38596 KB Output is correct
76 Correct 46 ms 35920 KB Output is correct
77 Correct 47 ms 35692 KB Output is correct
78 Correct 37 ms 35628 KB Output is correct
79 Correct 39 ms 35352 KB Output is correct
80 Correct 32 ms 34636 KB Output is correct
81 Correct 28 ms 34640 KB Output is correct
82 Correct 7 ms 29520 KB Output is correct
83 Correct 6 ms 29520 KB Output is correct
84 Correct 7 ms 29520 KB Output is correct
85 Correct 6 ms 29584 KB Output is correct
86 Correct 6 ms 29520 KB Output is correct
87 Correct 6 ms 29520 KB Output is correct
88 Correct 5 ms 27472 KB Output is correct
89 Correct 5 ms 27472 KB Output is correct
90 Correct 7 ms 27472 KB Output is correct
91 Correct 6 ms 27728 KB Output is correct
92 Correct 5 ms 27728 KB Output is correct
93 Correct 5 ms 27896 KB Output is correct
94 Correct 6 ms 27728 KB Output is correct
95 Correct 5 ms 27728 KB Output is correct
96 Correct 5 ms 27704 KB Output is correct
97 Correct 5 ms 27668 KB Output is correct
98 Correct 5 ms 27484 KB Output is correct
99 Correct 5 ms 27472 KB Output is correct
100 Correct 6 ms 27536 KB Output is correct
101 Correct 5 ms 27472 KB Output is correct
102 Correct 6 ms 27472 KB Output is correct
103 Correct 5 ms 27472 KB Output is correct
104 Correct 5 ms 27472 KB Output is correct
105 Correct 5 ms 27640 KB Output is correct
106 Correct 5 ms 27472 KB Output is correct
107 Correct 5 ms 27472 KB Output is correct
108 Correct 56 ms 38488 KB Output is correct
109 Correct 54 ms 38472 KB Output is correct
110 Correct 52 ms 38504 KB Output is correct
111 Correct 71 ms 38472 KB Output is correct
112 Correct 56 ms 38472 KB Output is correct
113 Correct 59 ms 48064 KB Output is correct
114 Correct 61 ms 44676 KB Output is correct
115 Correct 62 ms 43208 KB Output is correct
116 Correct 69 ms 41552 KB Output is correct
117 Correct 51 ms 38516 KB Output is correct
118 Correct 51 ms 38472 KB Output is correct
119 Correct 49 ms 38472 KB Output is correct
120 Correct 50 ms 38476 KB Output is correct
121 Correct 44 ms 37968 KB Output is correct
122 Correct 42 ms 37124 KB Output is correct
123 Correct 30 ms 35028 KB Output is correct
124 Correct 36 ms 37572 KB Output is correct
125 Correct 50 ms 37516 KB Output is correct
126 Correct 40 ms 37844 KB Output is correct
127 Correct 49 ms 37440 KB Output is correct
128 Correct 5 ms 27472 KB Output is correct
129 Correct 5 ms 27472 KB Output is correct
130 Correct 5 ms 27472 KB Output is correct
131 Correct 5 ms 27472 KB Output is correct
132 Correct 6 ms 27472 KB Output is correct
133 Correct 5 ms 27640 KB Output is correct
134 Correct 6 ms 27472 KB Output is correct
135 Correct 6 ms 27472 KB Output is correct
136 Correct 6 ms 27640 KB Output is correct
137 Correct 5 ms 27472 KB Output is correct
138 Correct 6 ms 27480 KB Output is correct
139 Correct 6 ms 27728 KB Output is correct
140 Correct 6 ms 27472 KB Output is correct
141 Correct 6 ms 27728 KB Output is correct
142 Correct 6 ms 27472 KB Output is correct
143 Correct 5 ms 27660 KB Output is correct
144 Correct 5 ms 27472 KB Output is correct
145 Correct 5 ms 27472 KB Output is correct
146 Correct 5 ms 27472 KB Output is correct
147 Correct 5 ms 27472 KB Output is correct
148 Correct 5 ms 27472 KB Output is correct
149 Correct 5 ms 27472 KB Output is correct
150 Correct 5 ms 27472 KB Output is correct
151 Correct 5 ms 27472 KB Output is correct
152 Correct 5 ms 27472 KB Output is correct
153 Correct 4 ms 27472 KB Output is correct
154 Correct 5 ms 27644 KB Output is correct
155 Correct 54 ms 38472 KB Output is correct
156 Correct 55 ms 38472 KB Output is correct
157 Correct 59 ms 37996 KB Output is correct
158 Correct 57 ms 37032 KB Output is correct
159 Correct 54 ms 35912 KB Output is correct
160 Correct 41 ms 35144 KB Output is correct
161 Correct 40 ms 34888 KB Output is correct
162 Correct 37 ms 34480 KB Output is correct
163 Correct 38 ms 34520 KB Output is correct
164 Correct 38 ms 34452 KB Output is correct
165 Correct 45 ms 34120 KB Output is correct
166 Correct 42 ms 34124 KB Output is correct
167 Correct 37 ms 34400 KB Output is correct
168 Correct 43 ms 37056 KB Output is correct
169 Correct 79 ms 44492 KB Output is correct
170 Correct 82 ms 42220 KB Output is correct
171 Correct 86 ms 42944 KB Output is correct
172 Correct 65 ms 41148 KB Output is correct
173 Correct 49 ms 36936 KB Output is correct
174 Correct 59 ms 36944 KB Output is correct
175 Correct 70 ms 36928 KB Output is correct
176 Correct 48 ms 36604 KB Output is correct
177 Correct 44 ms 35660 KB Output is correct
178 Correct 57 ms 37440 KB Output is correct
179 Correct 63 ms 37620 KB Output is correct
180 Correct 57 ms 36956 KB Output is correct
181 Correct 50 ms 37104 KB Output is correct
182 Correct 5 ms 27472 KB Output is correct
183 Correct 5 ms 27484 KB Output is correct
184 Correct 5 ms 27472 KB Output is correct
185 Correct 6 ms 27716 KB Output is correct
186 Correct 5 ms 27892 KB Output is correct
187 Correct 5 ms 27472 KB Output is correct
188 Correct 5 ms 27472 KB Output is correct
189 Correct 5 ms 27472 KB Output is correct
190 Correct 5 ms 27472 KB Output is correct
191 Correct 5 ms 27472 KB Output is correct
192 Correct 6 ms 27544 KB Output is correct
193 Correct 6 ms 27472 KB Output is correct
194 Correct 5 ms 27472 KB Output is correct
195 Correct 5 ms 27472 KB Output is correct
196 Correct 5 ms 27472 KB Output is correct
197 Correct 6 ms 27472 KB Output is correct
198 Correct 6 ms 27472 KB Output is correct
199 Correct 5 ms 27728 KB Output is correct
200 Correct 7 ms 27472 KB Output is correct
201 Correct 6 ms 27580 KB Output is correct
202 Correct 6 ms 27472 KB Output is correct
203 Correct 7 ms 27472 KB Output is correct
204 Correct 5 ms 27472 KB Output is correct
205 Correct 5 ms 27472 KB Output is correct
206 Correct 5 ms 27472 KB Output is correct
207 Correct 5 ms 27484 KB Output is correct
208 Correct 5 ms 27472 KB Output is correct
209 Correct 6 ms 29520 KB Output is correct
210 Correct 39 ms 34580 KB Output is correct
211 Correct 52 ms 38780 KB Output is correct
212 Correct 62 ms 41800 KB Output is correct
213 Correct 87 ms 43848 KB Output is correct
214 Correct 35 ms 35912 KB Output is correct
215 Correct 34 ms 35916 KB Output is correct
216 Correct 71 ms 37192 KB Output is correct
217 Correct 49 ms 35916 KB Output is correct
218 Correct 45 ms 34632 KB Output is correct
219 Correct 45 ms 34300 KB Output is correct
220 Correct 51 ms 34064 KB Output is correct
221 Correct 53 ms 34032 KB Output is correct
222 Correct 41 ms 35524 KB Output is correct
223 Correct 68 ms 39192 KB Output is correct
224 Correct 61 ms 38084 KB Output is correct
225 Correct 49 ms 35588 KB Output is correct
226 Correct 50 ms 35400 KB Output is correct
227 Correct 61 ms 35660 KB Output is correct
228 Correct 43 ms 35148 KB Output is correct
229 Correct 43 ms 34900 KB Output is correct
230 Correct 49 ms 35260 KB Output is correct
231 Correct 51 ms 35408 KB Output is correct