답안 #113213

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
113213 2019-05-24T10:46:02 Z 구사과(#2860, gs14004) Iqea (innopolis2018_final_C) C++14
100 / 100
781 ms 86672 KB
#include <bits/stdc++.h>
using namespace std;
const int MAXL = 20;
const int MAXN = 300005;
using lint = long long;
using pi = pair<int, int>;

struct point{
	int x, y, idx;
	bool operator<(const point &p)const{
		return pi(x, y) < pi(p.x, p.y);
	}
}a[MAXN];

struct namu{
	vector<int> gph[MAXN];
	int depth[MAXL][MAXN];
	int n, vtx[MAXN];
	int cpar[MAXN], cdep[MAXN];
	void add_edge(int x, int y){
		gph[x].push_back(y);
		gph[y].push_back(x);
	}
	int sz[MAXN], msz[MAXN], vis[MAXN];
	vector<int> dfn;
	void dfs(int x, int p){
		sz[x] = 1;
		dfn.push_back(x);
		msz[x] = 0;
		for(auto &i : gph[x]){
			if(i != p && !vis[i]){
				dfs(i, x);
				sz[x] += sz[i];
				msz[x] = max(msz[x], sz[i]);
			}
		}
	}
	int get_center(int x){
		dfn.clear();
		dfs(x, 0);
		int n = dfn.size();
		pi ret(1e9, 0);
		for(auto &i : dfn){
			int csz = max(msz[i], n - sz[i]);
			ret = min(ret, pi(csz, i));
		}
		return ret.second;
	}
	void fill_depth(int x, int p, int d, int pos){
		depth[pos][x] = d;
		for(auto &i : gph[x]){
			if(i != p && !vis[i]){
				fill_depth(i, x, d + 1, pos);
			}
		}
	}
	void Do(){
		for(int i=1; i<=n; i++){
			sort(gph[i].begin(), gph[i].end());
			gph[i].resize(unique(gph[i].begin(), gph[i].end()) - gph[i].begin());
		}
		queue<pi> que;
		que.emplace(1, 0);
		while(!que.empty()){
			int x, p;
			tie(x, p) = que.front();
			que.pop();
			x = get_center(x);
			vis[x] = 1;
			cpar[x] = p;
			cdep[x] = (p ? (cdep[p] + 1) : 0);
			fill_depth(x, 0, 0, cdep[x]);
			for(auto &i : gph[x]){
				if(!vis[i]){
					que.emplace(i, x);
				}
			}
		}
	}
}namu[2];

struct quer{
	int v1, v2, idx, t;
};

int aux[MAXN];
int n, q, ret[MAXN];
vector<quer> query[MAXN];

void Make1(int num){
	sort(a, a + n);
	for(int i=0; i<n; ){
		int e = i;
		while(e < n && a[e].x == a[i].x && a[e].y - a[i].y == e - i) e++;
		namu[num].n++;
		for(int j=i; j<e; j++){
			namu[num].vtx[a[j].idx] = namu[num].n;
		}
		i = e;
	}
}

void Make2(int num){
	sort(a, a + n);
	for(int i=1; i<n; i++){
		if(a[i].x == a[i-1].x && a[i-1].y + 1 == a[i].y){
			int l = namu[num].vtx[a[i-1].idx];
			int r = namu[num].vtx[a[i].idx];
			namu[num].add_edge(l, r);
		}
	}
}


int main(){
	map<pi, int> mp;
	scanf("%d",&n);
	for(int i=0; i<n; i++){
		scanf("%d %d",&a[i].x,&a[i].y);
		mp[pi(a[i].x, a[i].y)] = i;
		a[i].idx = i;
	}
	Make1(0);
	for(int i=0; i<n; i++) swap(a[i].x, a[i].y);
	Make1(1);
	for(int i=0; i<n; i++) swap(a[i].x, a[i].y);
	Make2(1);
	for(int i=0; i<n; i++) swap(a[i].x, a[i].y);
	Make2(0);
	for(int i=0; i<n; i++) swap(a[i].x, a[i].y);
	namu[0].Do();
	namu[1].Do();
	int q;
	memset(ret, 0x3f, sizeof(ret));
	scanf("%d",&q);
	vector<int> prnt;
	for(int i=0; i<q; i++){
		int t, x, y; scanf("%d %d %d",&t,&x,&y);
		int v = mp[pi(x, y)];
		x = namu[0].vtx[v];
		y = namu[1].vtx[v];
		for(int j = x; j != 0; j = namu[0].cpar[j]){
			query[j].push_back({x, y, i, t});
		}
		if(t == 2) prnt.push_back(i);
	}
	memset(aux, 0x3f, sizeof(aux));
	for(int i=1; i<=n; i++){
		for(auto &j : query[i]){
			if(j.t == 1){
				for(int k = j.v2; k != 0; k = namu[1].cpar[k]){
					aux[k] = min(aux[k], namu[0].depth[namu[0].cdep[i]][j.v1] + namu[1].depth[namu[1].cdep[k]][j.v2]);
				}
			}
			else{
				for(int k = j.v2; k != 0; k = namu[1].cpar[k]){
					ret[j.idx] = min(ret[j.idx], aux[k] + namu[0].depth[namu[0].cdep[i]][j.v1] + namu[1].depth[namu[1].cdep[k]][j.v2]);
				}
			}
		}
		for(auto &j : query[i]){
			if(j.t == 1){
				for(int k = j.v2; k != 0; k = namu[1].cpar[k]) aux[k] = 1e9;
			}
		}
	}
	for(auto &i : prnt){
		if(ret[i] > 1e8) ret[i] = -1;
		printf("%d\n", ret[i]);
	}
}

Compilation message

C.cpp: In function 'int main()':
C.cpp:117:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
  scanf("%d",&n);
  ~~~~~^~~~~~~~~
C.cpp:119:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   scanf("%d %d",&a[i].x,&a[i].y);
   ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
C.cpp:135:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
  scanf("%d",&q);
  ~~~~~^~~~~~~~~
C.cpp:138:21: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
   int t, x, y; scanf("%d %d %d",&t,&x,&y);
                ~~~~~^~~~~~~~~~~~~~~~~~~~~
# 결과 실행 시간 메모리 Grader output
1 Correct 22 ms 23936 KB Output is correct
2 Correct 21 ms 23936 KB Output is correct
3 Correct 21 ms 24060 KB Output is correct
4 Correct 30 ms 25216 KB Output is correct
5 Correct 28 ms 25216 KB Output is correct
6 Correct 31 ms 25208 KB Output is correct
7 Correct 34 ms 25984 KB Output is correct
8 Correct 35 ms 25984 KB Output is correct
9 Correct 34 ms 25976 KB Output is correct
10 Correct 33 ms 25724 KB Output is correct
11 Correct 34 ms 25876 KB Output is correct
12 Correct 34 ms 25856 KB Output is correct
13 Correct 35 ms 25900 KB Output is correct
14 Correct 35 ms 25976 KB Output is correct
15 Correct 35 ms 25848 KB Output is correct
16 Correct 35 ms 25984 KB Output is correct
17 Correct 34 ms 25848 KB Output is correct
18 Correct 35 ms 25720 KB Output is correct
19 Correct 34 ms 25720 KB Output is correct
20 Correct 37 ms 25976 KB Output is correct
21 Correct 39 ms 25856 KB Output is correct
22 Correct 36 ms 26104 KB Output is correct
23 Correct 37 ms 26232 KB Output is correct
24 Correct 36 ms 26360 KB Output is correct
25 Correct 34 ms 26456 KB Output is correct
26 Correct 31 ms 25336 KB Output is correct
27 Correct 30 ms 25472 KB Output is correct
28 Correct 38 ms 26376 KB Output is correct
29 Correct 41 ms 26360 KB Output is correct
30 Correct 45 ms 26488 KB Output is correct
31 Correct 35 ms 26368 KB Output is correct
32 Correct 36 ms 26204 KB Output is correct
33 Correct 36 ms 26232 KB Output is correct
34 Correct 39 ms 26392 KB Output is correct
35 Correct 38 ms 26248 KB Output is correct
36 Correct 34 ms 26488 KB Output is correct
37 Correct 45 ms 26360 KB Output is correct
38 Correct 39 ms 26216 KB Output is correct
39 Correct 36 ms 26356 KB Output is correct
40 Correct 34 ms 26360 KB Output is correct
41 Correct 35 ms 26232 KB Output is correct
42 Correct 34 ms 26240 KB Output is correct
43 Correct 53 ms 26360 KB Output is correct
44 Correct 46 ms 26104 KB Output is correct
45 Correct 35 ms 26112 KB Output is correct
46 Correct 29 ms 25464 KB Output is correct
47 Correct 33 ms 25848 KB Output is correct
48 Correct 33 ms 25592 KB Output is correct
49 Correct 32 ms 25592 KB Output is correct
50 Correct 32 ms 25472 KB Output is correct
51 Correct 31 ms 25472 KB Output is correct
52 Correct 32 ms 25592 KB Output is correct
53 Correct 36 ms 26112 KB Output is correct
54 Correct 34 ms 25856 KB Output is correct
55 Correct 33 ms 25848 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 22 ms 23936 KB Output is correct
2 Correct 21 ms 23936 KB Output is correct
3 Correct 21 ms 24060 KB Output is correct
4 Correct 30 ms 25216 KB Output is correct
5 Correct 28 ms 25216 KB Output is correct
6 Correct 31 ms 25208 KB Output is correct
7 Correct 34 ms 25984 KB Output is correct
8 Correct 35 ms 25984 KB Output is correct
9 Correct 34 ms 25976 KB Output is correct
10 Correct 33 ms 25724 KB Output is correct
11 Correct 34 ms 25876 KB Output is correct
12 Correct 34 ms 25856 KB Output is correct
13 Correct 35 ms 25900 KB Output is correct
14 Correct 35 ms 25976 KB Output is correct
15 Correct 35 ms 25848 KB Output is correct
16 Correct 35 ms 25984 KB Output is correct
17 Correct 34 ms 25848 KB Output is correct
18 Correct 35 ms 25720 KB Output is correct
19 Correct 34 ms 25720 KB Output is correct
20 Correct 37 ms 25976 KB Output is correct
21 Correct 39 ms 25856 KB Output is correct
22 Correct 36 ms 26104 KB Output is correct
23 Correct 37 ms 26232 KB Output is correct
24 Correct 36 ms 26360 KB Output is correct
25 Correct 34 ms 26456 KB Output is correct
26 Correct 31 ms 25336 KB Output is correct
27 Correct 30 ms 25472 KB Output is correct
28 Correct 38 ms 26376 KB Output is correct
29 Correct 41 ms 26360 KB Output is correct
30 Correct 45 ms 26488 KB Output is correct
31 Correct 35 ms 26368 KB Output is correct
32 Correct 36 ms 26204 KB Output is correct
33 Correct 36 ms 26232 KB Output is correct
34 Correct 39 ms 26392 KB Output is correct
35 Correct 38 ms 26248 KB Output is correct
36 Correct 34 ms 26488 KB Output is correct
37 Correct 45 ms 26360 KB Output is correct
38 Correct 39 ms 26216 KB Output is correct
39 Correct 36 ms 26356 KB Output is correct
40 Correct 34 ms 26360 KB Output is correct
41 Correct 35 ms 26232 KB Output is correct
42 Correct 34 ms 26240 KB Output is correct
43 Correct 53 ms 26360 KB Output is correct
44 Correct 46 ms 26104 KB Output is correct
45 Correct 35 ms 26112 KB Output is correct
46 Correct 29 ms 25464 KB Output is correct
47 Correct 33 ms 25848 KB Output is correct
48 Correct 33 ms 25592 KB Output is correct
49 Correct 32 ms 25592 KB Output is correct
50 Correct 32 ms 25472 KB Output is correct
51 Correct 31 ms 25472 KB Output is correct
52 Correct 32 ms 25592 KB Output is correct
53 Correct 36 ms 26112 KB Output is correct
54 Correct 34 ms 25856 KB Output is correct
55 Correct 33 ms 25848 KB Output is correct
56 Correct 112 ms 36908 KB Output is correct
57 Correct 117 ms 38840 KB Output is correct
58 Correct 119 ms 38236 KB Output is correct
59 Correct 160 ms 43164 KB Output is correct
60 Correct 182 ms 43096 KB Output is correct
61 Correct 156 ms 43340 KB Output is correct
62 Correct 158 ms 41812 KB Output is correct
63 Correct 155 ms 40996 KB Output is correct
64 Correct 161 ms 41700 KB Output is correct
65 Correct 151 ms 41592 KB Output is correct
66 Correct 153 ms 42356 KB Output is correct
67 Correct 154 ms 41740 KB Output is correct
68 Correct 155 ms 43340 KB Output is correct
69 Correct 151 ms 42344 KB Output is correct
70 Correct 144 ms 41756 KB Output is correct
71 Correct 142 ms 41048 KB Output is correct
72 Correct 152 ms 42584 KB Output is correct
73 Correct 157 ms 41660 KB Output is correct
74 Correct 192 ms 48704 KB Output is correct
75 Correct 100 ms 31076 KB Output is correct
76 Correct 89 ms 29572 KB Output is correct
77 Correct 183 ms 47576 KB Output is correct
78 Correct 182 ms 47576 KB Output is correct
79 Correct 207 ms 49972 KB Output is correct
80 Correct 170 ms 45364 KB Output is correct
81 Correct 174 ms 45524 KB Output is correct
82 Correct 173 ms 46424 KB Output is correct
83 Correct 174 ms 46944 KB Output is correct
84 Correct 156 ms 48820 KB Output is correct
85 Correct 167 ms 44160 KB Output is correct
86 Correct 167 ms 44384 KB Output is correct
87 Correct 87 ms 28960 KB Output is correct
88 Correct 153 ms 42268 KB Output is correct
89 Correct 140 ms 41744 KB Output is correct
90 Correct 141 ms 41440 KB Output is correct
91 Correct 134 ms 40040 KB Output is correct
92 Correct 126 ms 38696 KB Output is correct
93 Correct 137 ms 39876 KB Output is correct
94 Correct 160 ms 45008 KB Output is correct
95 Correct 222 ms 43356 KB Output is correct
96 Correct 156 ms 43480 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 339 ms 56436 KB Output is correct
2 Correct 492 ms 86672 KB Output is correct
3 Correct 524 ms 79360 KB Output is correct
4 Correct 519 ms 79708 KB Output is correct
5 Correct 624 ms 82032 KB Output is correct
6 Correct 595 ms 82032 KB Output is correct
7 Correct 371 ms 60384 KB Output is correct
8 Correct 358 ms 51964 KB Output is correct
9 Correct 307 ms 53904 KB Output is correct
10 Correct 398 ms 60744 KB Output is correct
11 Correct 357 ms 54564 KB Output is correct
12 Correct 353 ms 54044 KB Output is correct
13 Correct 313 ms 53728 KB Output is correct
14 Correct 313 ms 53540 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 543 ms 67812 KB Output is correct
2 Correct 551 ms 68516 KB Output is correct
3 Correct 555 ms 68624 KB Output is correct
4 Correct 781 ms 68112 KB Output is correct
5 Correct 524 ms 67172 KB Output is correct
6 Correct 547 ms 67296 KB Output is correct
7 Correct 555 ms 66940 KB Output is correct
8 Correct 523 ms 66772 KB Output is correct
9 Correct 566 ms 67476 KB Output is correct
10 Correct 597 ms 78412 KB Output is correct
11 Correct 636 ms 77304 KB Output is correct
12 Correct 673 ms 80252 KB Output is correct
13 Correct 490 ms 82560 KB Output is correct
14 Correct 430 ms 51396 KB Output is correct
15 Correct 305 ms 54900 KB Output is correct
16 Correct 666 ms 81096 KB Output is correct
17 Correct 538 ms 80980 KB Output is correct
18 Correct 529 ms 82000 KB Output is correct
19 Correct 623 ms 82196 KB Output is correct
20 Correct 702 ms 78000 KB Output is correct
21 Correct 682 ms 78688 KB Output is correct
22 Correct 645 ms 80112 KB Output is correct
23 Correct 633 ms 79172 KB Output is correct
24 Correct 634 ms 85472 KB Output is correct
25 Correct 650 ms 78416 KB Output is correct
26 Correct 555 ms 78432 KB Output is correct
27 Correct 564 ms 79420 KB Output is correct
28 Correct 639 ms 79368 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 22 ms 23936 KB Output is correct
2 Correct 21 ms 23936 KB Output is correct
3 Correct 21 ms 24060 KB Output is correct
4 Correct 30 ms 25216 KB Output is correct
5 Correct 28 ms 25216 KB Output is correct
6 Correct 31 ms 25208 KB Output is correct
7 Correct 34 ms 25984 KB Output is correct
8 Correct 35 ms 25984 KB Output is correct
9 Correct 34 ms 25976 KB Output is correct
10 Correct 33 ms 25724 KB Output is correct
11 Correct 34 ms 25876 KB Output is correct
12 Correct 34 ms 25856 KB Output is correct
13 Correct 35 ms 25900 KB Output is correct
14 Correct 35 ms 25976 KB Output is correct
15 Correct 35 ms 25848 KB Output is correct
16 Correct 35 ms 25984 KB Output is correct
17 Correct 34 ms 25848 KB Output is correct
18 Correct 35 ms 25720 KB Output is correct
19 Correct 34 ms 25720 KB Output is correct
20 Correct 37 ms 25976 KB Output is correct
21 Correct 39 ms 25856 KB Output is correct
22 Correct 36 ms 26104 KB Output is correct
23 Correct 37 ms 26232 KB Output is correct
24 Correct 36 ms 26360 KB Output is correct
25 Correct 34 ms 26456 KB Output is correct
26 Correct 31 ms 25336 KB Output is correct
27 Correct 30 ms 25472 KB Output is correct
28 Correct 38 ms 26376 KB Output is correct
29 Correct 41 ms 26360 KB Output is correct
30 Correct 45 ms 26488 KB Output is correct
31 Correct 35 ms 26368 KB Output is correct
32 Correct 36 ms 26204 KB Output is correct
33 Correct 36 ms 26232 KB Output is correct
34 Correct 39 ms 26392 KB Output is correct
35 Correct 38 ms 26248 KB Output is correct
36 Correct 34 ms 26488 KB Output is correct
37 Correct 45 ms 26360 KB Output is correct
38 Correct 39 ms 26216 KB Output is correct
39 Correct 36 ms 26356 KB Output is correct
40 Correct 34 ms 26360 KB Output is correct
41 Correct 35 ms 26232 KB Output is correct
42 Correct 34 ms 26240 KB Output is correct
43 Correct 53 ms 26360 KB Output is correct
44 Correct 46 ms 26104 KB Output is correct
45 Correct 35 ms 26112 KB Output is correct
46 Correct 29 ms 25464 KB Output is correct
47 Correct 33 ms 25848 KB Output is correct
48 Correct 33 ms 25592 KB Output is correct
49 Correct 32 ms 25592 KB Output is correct
50 Correct 32 ms 25472 KB Output is correct
51 Correct 31 ms 25472 KB Output is correct
52 Correct 32 ms 25592 KB Output is correct
53 Correct 36 ms 26112 KB Output is correct
54 Correct 34 ms 25856 KB Output is correct
55 Correct 33 ms 25848 KB Output is correct
56 Correct 112 ms 36908 KB Output is correct
57 Correct 117 ms 38840 KB Output is correct
58 Correct 119 ms 38236 KB Output is correct
59 Correct 160 ms 43164 KB Output is correct
60 Correct 182 ms 43096 KB Output is correct
61 Correct 156 ms 43340 KB Output is correct
62 Correct 158 ms 41812 KB Output is correct
63 Correct 155 ms 40996 KB Output is correct
64 Correct 161 ms 41700 KB Output is correct
65 Correct 151 ms 41592 KB Output is correct
66 Correct 153 ms 42356 KB Output is correct
67 Correct 154 ms 41740 KB Output is correct
68 Correct 155 ms 43340 KB Output is correct
69 Correct 151 ms 42344 KB Output is correct
70 Correct 144 ms 41756 KB Output is correct
71 Correct 142 ms 41048 KB Output is correct
72 Correct 152 ms 42584 KB Output is correct
73 Correct 157 ms 41660 KB Output is correct
74 Correct 192 ms 48704 KB Output is correct
75 Correct 100 ms 31076 KB Output is correct
76 Correct 89 ms 29572 KB Output is correct
77 Correct 183 ms 47576 KB Output is correct
78 Correct 182 ms 47576 KB Output is correct
79 Correct 207 ms 49972 KB Output is correct
80 Correct 170 ms 45364 KB Output is correct
81 Correct 174 ms 45524 KB Output is correct
82 Correct 173 ms 46424 KB Output is correct
83 Correct 174 ms 46944 KB Output is correct
84 Correct 156 ms 48820 KB Output is correct
85 Correct 167 ms 44160 KB Output is correct
86 Correct 167 ms 44384 KB Output is correct
87 Correct 87 ms 28960 KB Output is correct
88 Correct 153 ms 42268 KB Output is correct
89 Correct 140 ms 41744 KB Output is correct
90 Correct 141 ms 41440 KB Output is correct
91 Correct 134 ms 40040 KB Output is correct
92 Correct 126 ms 38696 KB Output is correct
93 Correct 137 ms 39876 KB Output is correct
94 Correct 160 ms 45008 KB Output is correct
95 Correct 222 ms 43356 KB Output is correct
96 Correct 156 ms 43480 KB Output is correct
97 Correct 339 ms 56436 KB Output is correct
98 Correct 492 ms 86672 KB Output is correct
99 Correct 524 ms 79360 KB Output is correct
100 Correct 519 ms 79708 KB Output is correct
101 Correct 624 ms 82032 KB Output is correct
102 Correct 595 ms 82032 KB Output is correct
103 Correct 371 ms 60384 KB Output is correct
104 Correct 358 ms 51964 KB Output is correct
105 Correct 307 ms 53904 KB Output is correct
106 Correct 398 ms 60744 KB Output is correct
107 Correct 357 ms 54564 KB Output is correct
108 Correct 353 ms 54044 KB Output is correct
109 Correct 313 ms 53728 KB Output is correct
110 Correct 313 ms 53540 KB Output is correct
111 Correct 543 ms 67812 KB Output is correct
112 Correct 551 ms 68516 KB Output is correct
113 Correct 555 ms 68624 KB Output is correct
114 Correct 781 ms 68112 KB Output is correct
115 Correct 524 ms 67172 KB Output is correct
116 Correct 547 ms 67296 KB Output is correct
117 Correct 555 ms 66940 KB Output is correct
118 Correct 523 ms 66772 KB Output is correct
119 Correct 566 ms 67476 KB Output is correct
120 Correct 597 ms 78412 KB Output is correct
121 Correct 636 ms 77304 KB Output is correct
122 Correct 673 ms 80252 KB Output is correct
123 Correct 490 ms 82560 KB Output is correct
124 Correct 430 ms 51396 KB Output is correct
125 Correct 305 ms 54900 KB Output is correct
126 Correct 666 ms 81096 KB Output is correct
127 Correct 538 ms 80980 KB Output is correct
128 Correct 529 ms 82000 KB Output is correct
129 Correct 623 ms 82196 KB Output is correct
130 Correct 702 ms 78000 KB Output is correct
131 Correct 682 ms 78688 KB Output is correct
132 Correct 645 ms 80112 KB Output is correct
133 Correct 633 ms 79172 KB Output is correct
134 Correct 634 ms 85472 KB Output is correct
135 Correct 650 ms 78416 KB Output is correct
136 Correct 555 ms 78432 KB Output is correct
137 Correct 564 ms 79420 KB Output is correct
138 Correct 639 ms 79368 KB Output is correct
139 Correct 312 ms 49276 KB Output is correct
140 Correct 330 ms 53088 KB Output is correct
141 Correct 360 ms 51928 KB Output is correct
142 Correct 357 ms 53152 KB Output is correct
143 Correct 657 ms 66780 KB Output is correct
144 Correct 654 ms 67192 KB Output is correct
145 Correct 499 ms 64956 KB Output is correct
146 Correct 528 ms 62488 KB Output is correct
147 Correct 664 ms 68320 KB Output is correct
148 Correct 698 ms 67932 KB Output is correct
149 Correct 631 ms 78596 KB Output is correct
150 Correct 634 ms 77164 KB Output is correct
151 Correct 584 ms 81244 KB Output is correct
152 Correct 539 ms 75744 KB Output is correct
153 Correct 585 ms 74884 KB Output is correct
154 Correct 283 ms 49980 KB Output is correct
155 Correct 520 ms 64224 KB Output is correct
156 Correct 487 ms 62368 KB Output is correct
157 Correct 464 ms 61104 KB Output is correct
158 Correct 442 ms 58372 KB Output is correct
159 Correct 439 ms 57204 KB Output is correct
160 Correct 496 ms 66040 KB Output is correct
161 Correct 578 ms 71884 KB Output is correct
162 Correct 572 ms 68876 KB Output is correct
163 Correct 526 ms 68484 KB Output is correct