using namespace std;
#include <iostream>
#include <algorithm>
#include <vector>
#include <utility>
#include <set>
#include <map>
#include <stack>
#include <queue>
#include <deque>
typedef long long LL;
typedef pair<int,int> pii;
#define pb push_back
#define mkp make_pair
#define F first
#define S second
#define REP(n) for (int __=n;__--;)
#define REP1(i,n) for (int i=1;i<=n;++i)
#define REP0(i,n) for (int i=0;i<n;++i)
typedef vector <int> vi;
#include "parks.h"
int dx[4] = {2,0,-2,0},dy[4] = {0,2,0,-2};
int dfx[8] = {1,1,1,-1,-1,-1,-1,1}, dfy[8] = {-1,1,1,1,1,-1,-1,-1};
map <pii,bool> vis;
vi u,v,fx,fy;
set <pii> ben;
map <pii,int> mp;
void dfs(int x,int y){
vis[mkp(x,y)] = true;
int fr = -1;
REP0(i,4) if (vis.find(mkp(x+dx[i],y+dy[i])) != vis.end()){
if (vis[mkp(x+dx[i],y+dy[i])]) fr = i;
}
int c = 0;
for(int i=(fr+1)%4;c<4;i=(i+1)%4,++c) if (vis.find(mkp(x+dx[i],y+dy[i])) != vis.end() and !vis[mkp(x+dx[i],y+dy[i])]){
u.pb(mp[mkp(x,y)]);
v.pb(mp[mkp(x+dx[i],y+dy[i])]);
if (ben.find(mkp(x+dfx[i*2],y+dfy[i*2])) == ben.end()){
ben.insert(mkp(x+dfx[i*2],y+dfy[i*2]));
fx.pb(x+dfx[i*2]);
fy.pb(y+dfy[i*2]);
}
else{
ben.insert(mkp(x+dfx[i*2+1],y+dfy[i*2+1]));
fx.pb(x+dfx[i*2+1]);
fy.pb(y+dfy[i*2+1]);
}
dfs(x+dx[i],y+dy[i]);
}
}
int construct_roads(vi x,vi y){
int n = x.size();
REP0(i,n) vis[mkp(x[i],y[i])] = false;
REP0(i,n) mp[mkp(x[i],y[i])] = i;
dfs(x[0],y[0]);
for (auto [p,v]:vis) if (!v) return false;
/*
REP0(i,n){
if (mp.find(mkp(x[i]+2,y[i])) != mp.end()){
u.pb(i);
v.pb(mp[mkp(x[i]+2,y[i])]);
fx.pb(3);
fy.pb(y[i]-1);
}
if (mp.find(mkp(x[i],y[i]+2)) != mp.end()){
u.pb(i);
v.pb(mp[mkp(x[i],y[i]+2)]);
if (x[i] == 2) fx.pb(1);
else fx.pb(5);
fy.pb(y[i]+1);
}
}
*/
build(u,v,fx,fy);
return true;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
204 KB |
Output is correct |
2 |
Correct |
1 ms |
204 KB |
Output is correct |
3 |
Correct |
0 ms |
204 KB |
Output is correct |
4 |
Correct |
0 ms |
204 KB |
Output is correct |
5 |
Correct |
1 ms |
204 KB |
Output is correct |
6 |
Correct |
0 ms |
204 KB |
Output is correct |
7 |
Correct |
0 ms |
204 KB |
Output is correct |
8 |
Correct |
0 ms |
292 KB |
Output is correct |
9 |
Correct |
278 ms |
37568 KB |
Output is correct |
10 |
Correct |
22 ms |
4220 KB |
Output is correct |
11 |
Correct |
153 ms |
21016 KB |
Output is correct |
12 |
Correct |
34 ms |
6252 KB |
Output is correct |
13 |
Correct |
79 ms |
12964 KB |
Output is correct |
14 |
Correct |
1 ms |
460 KB |
Output is correct |
15 |
Correct |
2 ms |
588 KB |
Output is correct |
16 |
Correct |
263 ms |
31752 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
204 KB |
Output is correct |
2 |
Correct |
1 ms |
204 KB |
Output is correct |
3 |
Correct |
0 ms |
204 KB |
Output is correct |
4 |
Correct |
0 ms |
204 KB |
Output is correct |
5 |
Correct |
1 ms |
204 KB |
Output is correct |
6 |
Correct |
0 ms |
204 KB |
Output is correct |
7 |
Correct |
0 ms |
204 KB |
Output is correct |
8 |
Correct |
0 ms |
292 KB |
Output is correct |
9 |
Correct |
278 ms |
37568 KB |
Output is correct |
10 |
Correct |
22 ms |
4220 KB |
Output is correct |
11 |
Correct |
153 ms |
21016 KB |
Output is correct |
12 |
Correct |
34 ms |
6252 KB |
Output is correct |
13 |
Correct |
79 ms |
12964 KB |
Output is correct |
14 |
Correct |
1 ms |
460 KB |
Output is correct |
15 |
Correct |
2 ms |
588 KB |
Output is correct |
16 |
Correct |
263 ms |
31752 KB |
Output is correct |
17 |
Correct |
0 ms |
204 KB |
Output is correct |
18 |
Correct |
0 ms |
204 KB |
Output is correct |
19 |
Correct |
1 ms |
204 KB |
Output is correct |
20 |
Correct |
1 ms |
204 KB |
Output is correct |
21 |
Correct |
0 ms |
204 KB |
Output is correct |
22 |
Correct |
1 ms |
288 KB |
Output is correct |
23 |
Correct |
752 ms |
76800 KB |
Output is correct |
24 |
Correct |
0 ms |
204 KB |
Output is correct |
25 |
Correct |
2 ms |
716 KB |
Output is correct |
26 |
Correct |
4 ms |
844 KB |
Output is correct |
27 |
Correct |
3 ms |
972 KB |
Output is correct |
28 |
Correct |
245 ms |
30744 KB |
Output is correct |
29 |
Correct |
388 ms |
42464 KB |
Output is correct |
30 |
Correct |
574 ms |
59940 KB |
Output is correct |
31 |
Correct |
718 ms |
76856 KB |
Output is correct |
32 |
Correct |
1 ms |
204 KB |
Output is correct |
33 |
Correct |
0 ms |
204 KB |
Output is correct |
34 |
Correct |
0 ms |
204 KB |
Output is correct |
35 |
Correct |
1 ms |
204 KB |
Output is correct |
36 |
Correct |
0 ms |
204 KB |
Output is correct |
37 |
Correct |
0 ms |
204 KB |
Output is correct |
38 |
Correct |
1 ms |
204 KB |
Output is correct |
39 |
Correct |
0 ms |
204 KB |
Output is correct |
40 |
Correct |
1 ms |
204 KB |
Output is correct |
41 |
Correct |
1 ms |
204 KB |
Output is correct |
42 |
Correct |
0 ms |
204 KB |
Output is correct |
43 |
Correct |
3 ms |
716 KB |
Output is correct |
44 |
Correct |
3 ms |
844 KB |
Output is correct |
45 |
Correct |
304 ms |
33328 KB |
Output is correct |
46 |
Correct |
457 ms |
48996 KB |
Output is correct |
47 |
Correct |
506 ms |
48052 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
204 KB |
Output is correct |
2 |
Correct |
1 ms |
204 KB |
Output is correct |
3 |
Correct |
0 ms |
204 KB |
Output is correct |
4 |
Correct |
0 ms |
204 KB |
Output is correct |
5 |
Correct |
1 ms |
204 KB |
Output is correct |
6 |
Correct |
0 ms |
204 KB |
Output is correct |
7 |
Correct |
0 ms |
204 KB |
Output is correct |
8 |
Correct |
0 ms |
292 KB |
Output is correct |
9 |
Correct |
278 ms |
37568 KB |
Output is correct |
10 |
Correct |
22 ms |
4220 KB |
Output is correct |
11 |
Correct |
153 ms |
21016 KB |
Output is correct |
12 |
Correct |
34 ms |
6252 KB |
Output is correct |
13 |
Correct |
79 ms |
12964 KB |
Output is correct |
14 |
Correct |
1 ms |
460 KB |
Output is correct |
15 |
Correct |
2 ms |
588 KB |
Output is correct |
16 |
Correct |
263 ms |
31752 KB |
Output is correct |
17 |
Correct |
0 ms |
204 KB |
Output is correct |
18 |
Correct |
0 ms |
204 KB |
Output is correct |
19 |
Correct |
1 ms |
204 KB |
Output is correct |
20 |
Correct |
1 ms |
204 KB |
Output is correct |
21 |
Correct |
0 ms |
204 KB |
Output is correct |
22 |
Correct |
1 ms |
288 KB |
Output is correct |
23 |
Correct |
752 ms |
76800 KB |
Output is correct |
24 |
Correct |
0 ms |
204 KB |
Output is correct |
25 |
Correct |
2 ms |
716 KB |
Output is correct |
26 |
Correct |
4 ms |
844 KB |
Output is correct |
27 |
Correct |
3 ms |
972 KB |
Output is correct |
28 |
Correct |
245 ms |
30744 KB |
Output is correct |
29 |
Correct |
388 ms |
42464 KB |
Output is correct |
30 |
Correct |
574 ms |
59940 KB |
Output is correct |
31 |
Correct |
718 ms |
76856 KB |
Output is correct |
32 |
Correct |
1 ms |
204 KB |
Output is correct |
33 |
Correct |
0 ms |
204 KB |
Output is correct |
34 |
Correct |
0 ms |
204 KB |
Output is correct |
35 |
Correct |
1 ms |
204 KB |
Output is correct |
36 |
Correct |
0 ms |
204 KB |
Output is correct |
37 |
Correct |
0 ms |
204 KB |
Output is correct |
38 |
Correct |
1 ms |
204 KB |
Output is correct |
39 |
Correct |
0 ms |
204 KB |
Output is correct |
40 |
Correct |
1 ms |
204 KB |
Output is correct |
41 |
Correct |
1 ms |
204 KB |
Output is correct |
42 |
Correct |
0 ms |
204 KB |
Output is correct |
43 |
Correct |
3 ms |
716 KB |
Output is correct |
44 |
Correct |
3 ms |
844 KB |
Output is correct |
45 |
Correct |
304 ms |
33328 KB |
Output is correct |
46 |
Correct |
457 ms |
48996 KB |
Output is correct |
47 |
Correct |
506 ms |
48052 KB |
Output is correct |
48 |
Correct |
1 ms |
204 KB |
Output is correct |
49 |
Correct |
0 ms |
292 KB |
Output is correct |
50 |
Correct |
1 ms |
204 KB |
Output is correct |
51 |
Correct |
1 ms |
204 KB |
Output is correct |
52 |
Correct |
1 ms |
204 KB |
Output is correct |
53 |
Correct |
1 ms |
296 KB |
Output is correct |
54 |
Correct |
1 ms |
204 KB |
Output is correct |
55 |
Correct |
733 ms |
74364 KB |
Output is correct |
56 |
Correct |
0 ms |
204 KB |
Output is correct |
57 |
Correct |
5 ms |
844 KB |
Output is correct |
58 |
Correct |
17 ms |
2528 KB |
Output is correct |
59 |
Correct |
10 ms |
2124 KB |
Output is correct |
60 |
Correct |
296 ms |
38280 KB |
Output is correct |
61 |
Correct |
437 ms |
49980 KB |
Output is correct |
62 |
Correct |
565 ms |
61848 KB |
Output is correct |
63 |
Correct |
715 ms |
74136 KB |
Output is correct |
64 |
Correct |
0 ms |
204 KB |
Output is correct |
65 |
Correct |
0 ms |
204 KB |
Output is correct |
66 |
Correct |
0 ms |
204 KB |
Output is correct |
67 |
Correct |
607 ms |
68948 KB |
Output is correct |
68 |
Correct |
624 ms |
69392 KB |
Output is correct |
69 |
Correct |
613 ms |
72180 KB |
Output is correct |
70 |
Correct |
6 ms |
1100 KB |
Output is correct |
71 |
Correct |
7 ms |
1740 KB |
Output is correct |
72 |
Correct |
282 ms |
29168 KB |
Output is correct |
73 |
Correct |
464 ms |
47320 KB |
Output is correct |
74 |
Correct |
661 ms |
58652 KB |
Output is correct |
75 |
Correct |
677 ms |
71064 KB |
Output is correct |
76 |
Correct |
648 ms |
77080 KB |
Output is correct |
77 |
Correct |
6 ms |
1356 KB |
Output is correct |
78 |
Correct |
10 ms |
1996 KB |
Output is correct |
79 |
Correct |
287 ms |
30376 KB |
Output is correct |
80 |
Correct |
463 ms |
45976 KB |
Output is correct |
81 |
Correct |
636 ms |
61476 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
204 KB |
Output is correct |
2 |
Correct |
1 ms |
204 KB |
Output is correct |
3 |
Correct |
0 ms |
204 KB |
Output is correct |
4 |
Correct |
0 ms |
204 KB |
Output is correct |
5 |
Correct |
1 ms |
204 KB |
Output is correct |
6 |
Correct |
0 ms |
204 KB |
Output is correct |
7 |
Correct |
0 ms |
204 KB |
Output is correct |
8 |
Correct |
0 ms |
292 KB |
Output is correct |
9 |
Correct |
278 ms |
37568 KB |
Output is correct |
10 |
Correct |
22 ms |
4220 KB |
Output is correct |
11 |
Correct |
153 ms |
21016 KB |
Output is correct |
12 |
Correct |
34 ms |
6252 KB |
Output is correct |
13 |
Correct |
79 ms |
12964 KB |
Output is correct |
14 |
Correct |
1 ms |
460 KB |
Output is correct |
15 |
Correct |
2 ms |
588 KB |
Output is correct |
16 |
Correct |
263 ms |
31752 KB |
Output is correct |
17 |
Correct |
0 ms |
204 KB |
Output is correct |
18 |
Correct |
0 ms |
204 KB |
Output is correct |
19 |
Correct |
0 ms |
204 KB |
Output is correct |
20 |
Correct |
683 ms |
76604 KB |
Output is correct |
21 |
Correct |
689 ms |
70852 KB |
Output is correct |
22 |
Correct |
683 ms |
67836 KB |
Output is correct |
23 |
Correct |
518 ms |
56768 KB |
Output is correct |
24 |
Correct |
250 ms |
30116 KB |
Output is correct |
25 |
Correct |
229 ms |
30132 KB |
Output is correct |
26 |
Correct |
232 ms |
30148 KB |
Output is correct |
27 |
Correct |
564 ms |
48884 KB |
Output is correct |
28 |
Correct |
550 ms |
49060 KB |
Output is correct |
29 |
Correct |
853 ms |
49064 KB |
Output is correct |
30 |
Correct |
862 ms |
49128 KB |
Output is correct |
31 |
Correct |
0 ms |
204 KB |
Output is correct |
32 |
Correct |
38 ms |
4932 KB |
Output is correct |
33 |
Correct |
95 ms |
15684 KB |
Output is correct |
34 |
Correct |
636 ms |
73268 KB |
Output is correct |
35 |
Correct |
13 ms |
2124 KB |
Output is correct |
36 |
Correct |
61 ms |
8664 KB |
Output is correct |
37 |
Correct |
116 ms |
16356 KB |
Output is correct |
38 |
Correct |
227 ms |
20416 KB |
Output is correct |
39 |
Correct |
333 ms |
27708 KB |
Output is correct |
40 |
Correct |
441 ms |
35264 KB |
Output is correct |
41 |
Correct |
561 ms |
42828 KB |
Output is correct |
42 |
Correct |
701 ms |
50532 KB |
Output is correct |
43 |
Correct |
0 ms |
204 KB |
Output is correct |
44 |
Correct |
0 ms |
204 KB |
Output is correct |
45 |
Correct |
0 ms |
204 KB |
Output is correct |
46 |
Correct |
0 ms |
204 KB |
Output is correct |
47 |
Correct |
0 ms |
204 KB |
Output is correct |
48 |
Correct |
0 ms |
204 KB |
Output is correct |
49 |
Correct |
1 ms |
204 KB |
Output is correct |
50 |
Correct |
0 ms |
204 KB |
Output is correct |
51 |
Correct |
1 ms |
288 KB |
Output is correct |
52 |
Correct |
1 ms |
204 KB |
Output is correct |
53 |
Correct |
0 ms |
204 KB |
Output is correct |
54 |
Correct |
2 ms |
716 KB |
Output is correct |
55 |
Correct |
2 ms |
844 KB |
Output is correct |
56 |
Correct |
278 ms |
33332 KB |
Output is correct |
57 |
Correct |
440 ms |
49076 KB |
Output is correct |
58 |
Correct |
437 ms |
48080 KB |
Output is correct |
59 |
Correct |
1 ms |
204 KB |
Output is correct |
60 |
Correct |
1 ms |
288 KB |
Output is correct |
61 |
Correct |
0 ms |
204 KB |
Output is correct |
62 |
Correct |
594 ms |
68944 KB |
Output is correct |
63 |
Correct |
595 ms |
69496 KB |
Output is correct |
64 |
Correct |
602 ms |
72184 KB |
Output is correct |
65 |
Correct |
5 ms |
1100 KB |
Output is correct |
66 |
Correct |
7 ms |
1740 KB |
Output is correct |
67 |
Correct |
296 ms |
29192 KB |
Output is correct |
68 |
Correct |
461 ms |
47256 KB |
Output is correct |
69 |
Correct |
651 ms |
58652 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
204 KB |
Output is correct |
2 |
Correct |
1 ms |
204 KB |
Output is correct |
3 |
Correct |
0 ms |
204 KB |
Output is correct |
4 |
Correct |
0 ms |
204 KB |
Output is correct |
5 |
Correct |
1 ms |
204 KB |
Output is correct |
6 |
Correct |
0 ms |
204 KB |
Output is correct |
7 |
Correct |
0 ms |
204 KB |
Output is correct |
8 |
Correct |
0 ms |
292 KB |
Output is correct |
9 |
Correct |
278 ms |
37568 KB |
Output is correct |
10 |
Correct |
22 ms |
4220 KB |
Output is correct |
11 |
Correct |
153 ms |
21016 KB |
Output is correct |
12 |
Correct |
34 ms |
6252 KB |
Output is correct |
13 |
Correct |
79 ms |
12964 KB |
Output is correct |
14 |
Correct |
1 ms |
460 KB |
Output is correct |
15 |
Correct |
2 ms |
588 KB |
Output is correct |
16 |
Correct |
263 ms |
31752 KB |
Output is correct |
17 |
Correct |
641 ms |
76788 KB |
Output is correct |
18 |
Correct |
629 ms |
65512 KB |
Output is correct |
19 |
Correct |
686 ms |
76964 KB |
Output is correct |
20 |
Correct |
743 ms |
66336 KB |
Output is correct |
21 |
Correct |
622 ms |
56676 KB |
Output is correct |
22 |
Correct |
0 ms |
204 KB |
Output is correct |
23 |
Correct |
91 ms |
9716 KB |
Output is correct |
24 |
Correct |
30 ms |
4808 KB |
Output is correct |
25 |
Correct |
80 ms |
12744 KB |
Output is correct |
26 |
Correct |
143 ms |
20392 KB |
Output is correct |
27 |
Correct |
343 ms |
34128 KB |
Output is correct |
28 |
Correct |
441 ms |
43060 KB |
Output is correct |
29 |
Correct |
544 ms |
51916 KB |
Output is correct |
30 |
Correct |
674 ms |
59792 KB |
Output is correct |
31 |
Correct |
777 ms |
68688 KB |
Output is correct |
32 |
Correct |
666 ms |
70864 KB |
Output is correct |
33 |
Correct |
620 ms |
77088 KB |
Output is correct |
34 |
Correct |
6 ms |
1356 KB |
Output is correct |
35 |
Correct |
10 ms |
1996 KB |
Output is correct |
36 |
Correct |
289 ms |
30236 KB |
Output is correct |
37 |
Correct |
455 ms |
45968 KB |
Output is correct |
38 |
Correct |
698 ms |
61516 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
204 KB |
Output is correct |
2 |
Correct |
1 ms |
204 KB |
Output is correct |
3 |
Correct |
0 ms |
204 KB |
Output is correct |
4 |
Correct |
0 ms |
204 KB |
Output is correct |
5 |
Correct |
1 ms |
204 KB |
Output is correct |
6 |
Correct |
0 ms |
204 KB |
Output is correct |
7 |
Correct |
0 ms |
204 KB |
Output is correct |
8 |
Correct |
0 ms |
292 KB |
Output is correct |
9 |
Correct |
278 ms |
37568 KB |
Output is correct |
10 |
Correct |
22 ms |
4220 KB |
Output is correct |
11 |
Correct |
153 ms |
21016 KB |
Output is correct |
12 |
Correct |
34 ms |
6252 KB |
Output is correct |
13 |
Correct |
79 ms |
12964 KB |
Output is correct |
14 |
Correct |
1 ms |
460 KB |
Output is correct |
15 |
Correct |
2 ms |
588 KB |
Output is correct |
16 |
Correct |
263 ms |
31752 KB |
Output is correct |
17 |
Correct |
0 ms |
204 KB |
Output is correct |
18 |
Correct |
0 ms |
204 KB |
Output is correct |
19 |
Correct |
1 ms |
204 KB |
Output is correct |
20 |
Correct |
1 ms |
204 KB |
Output is correct |
21 |
Correct |
0 ms |
204 KB |
Output is correct |
22 |
Correct |
1 ms |
288 KB |
Output is correct |
23 |
Correct |
752 ms |
76800 KB |
Output is correct |
24 |
Correct |
0 ms |
204 KB |
Output is correct |
25 |
Correct |
2 ms |
716 KB |
Output is correct |
26 |
Correct |
4 ms |
844 KB |
Output is correct |
27 |
Correct |
3 ms |
972 KB |
Output is correct |
28 |
Correct |
245 ms |
30744 KB |
Output is correct |
29 |
Correct |
388 ms |
42464 KB |
Output is correct |
30 |
Correct |
574 ms |
59940 KB |
Output is correct |
31 |
Correct |
718 ms |
76856 KB |
Output is correct |
32 |
Correct |
1 ms |
204 KB |
Output is correct |
33 |
Correct |
0 ms |
204 KB |
Output is correct |
34 |
Correct |
0 ms |
204 KB |
Output is correct |
35 |
Correct |
1 ms |
204 KB |
Output is correct |
36 |
Correct |
0 ms |
204 KB |
Output is correct |
37 |
Correct |
0 ms |
204 KB |
Output is correct |
38 |
Correct |
1 ms |
204 KB |
Output is correct |
39 |
Correct |
0 ms |
204 KB |
Output is correct |
40 |
Correct |
1 ms |
204 KB |
Output is correct |
41 |
Correct |
1 ms |
204 KB |
Output is correct |
42 |
Correct |
0 ms |
204 KB |
Output is correct |
43 |
Correct |
3 ms |
716 KB |
Output is correct |
44 |
Correct |
3 ms |
844 KB |
Output is correct |
45 |
Correct |
304 ms |
33328 KB |
Output is correct |
46 |
Correct |
457 ms |
48996 KB |
Output is correct |
47 |
Correct |
506 ms |
48052 KB |
Output is correct |
48 |
Correct |
1 ms |
204 KB |
Output is correct |
49 |
Correct |
0 ms |
292 KB |
Output is correct |
50 |
Correct |
1 ms |
204 KB |
Output is correct |
51 |
Correct |
1 ms |
204 KB |
Output is correct |
52 |
Correct |
1 ms |
204 KB |
Output is correct |
53 |
Correct |
1 ms |
296 KB |
Output is correct |
54 |
Correct |
1 ms |
204 KB |
Output is correct |
55 |
Correct |
733 ms |
74364 KB |
Output is correct |
56 |
Correct |
0 ms |
204 KB |
Output is correct |
57 |
Correct |
5 ms |
844 KB |
Output is correct |
58 |
Correct |
17 ms |
2528 KB |
Output is correct |
59 |
Correct |
10 ms |
2124 KB |
Output is correct |
60 |
Correct |
296 ms |
38280 KB |
Output is correct |
61 |
Correct |
437 ms |
49980 KB |
Output is correct |
62 |
Correct |
565 ms |
61848 KB |
Output is correct |
63 |
Correct |
715 ms |
74136 KB |
Output is correct |
64 |
Correct |
0 ms |
204 KB |
Output is correct |
65 |
Correct |
0 ms |
204 KB |
Output is correct |
66 |
Correct |
0 ms |
204 KB |
Output is correct |
67 |
Correct |
607 ms |
68948 KB |
Output is correct |
68 |
Correct |
624 ms |
69392 KB |
Output is correct |
69 |
Correct |
613 ms |
72180 KB |
Output is correct |
70 |
Correct |
6 ms |
1100 KB |
Output is correct |
71 |
Correct |
7 ms |
1740 KB |
Output is correct |
72 |
Correct |
282 ms |
29168 KB |
Output is correct |
73 |
Correct |
464 ms |
47320 KB |
Output is correct |
74 |
Correct |
661 ms |
58652 KB |
Output is correct |
75 |
Correct |
677 ms |
71064 KB |
Output is correct |
76 |
Correct |
648 ms |
77080 KB |
Output is correct |
77 |
Correct |
6 ms |
1356 KB |
Output is correct |
78 |
Correct |
10 ms |
1996 KB |
Output is correct |
79 |
Correct |
287 ms |
30376 KB |
Output is correct |
80 |
Correct |
463 ms |
45976 KB |
Output is correct |
81 |
Correct |
636 ms |
61476 KB |
Output is correct |
82 |
Correct |
0 ms |
204 KB |
Output is correct |
83 |
Correct |
0 ms |
204 KB |
Output is correct |
84 |
Correct |
0 ms |
204 KB |
Output is correct |
85 |
Correct |
683 ms |
76604 KB |
Output is correct |
86 |
Correct |
689 ms |
70852 KB |
Output is correct |
87 |
Correct |
683 ms |
67836 KB |
Output is correct |
88 |
Correct |
518 ms |
56768 KB |
Output is correct |
89 |
Correct |
250 ms |
30116 KB |
Output is correct |
90 |
Correct |
229 ms |
30132 KB |
Output is correct |
91 |
Correct |
232 ms |
30148 KB |
Output is correct |
92 |
Correct |
564 ms |
48884 KB |
Output is correct |
93 |
Correct |
550 ms |
49060 KB |
Output is correct |
94 |
Correct |
853 ms |
49064 KB |
Output is correct |
95 |
Correct |
862 ms |
49128 KB |
Output is correct |
96 |
Correct |
0 ms |
204 KB |
Output is correct |
97 |
Correct |
38 ms |
4932 KB |
Output is correct |
98 |
Correct |
95 ms |
15684 KB |
Output is correct |
99 |
Correct |
636 ms |
73268 KB |
Output is correct |
100 |
Correct |
13 ms |
2124 KB |
Output is correct |
101 |
Correct |
61 ms |
8664 KB |
Output is correct |
102 |
Correct |
116 ms |
16356 KB |
Output is correct |
103 |
Correct |
227 ms |
20416 KB |
Output is correct |
104 |
Correct |
333 ms |
27708 KB |
Output is correct |
105 |
Correct |
441 ms |
35264 KB |
Output is correct |
106 |
Correct |
561 ms |
42828 KB |
Output is correct |
107 |
Correct |
701 ms |
50532 KB |
Output is correct |
108 |
Correct |
0 ms |
204 KB |
Output is correct |
109 |
Correct |
0 ms |
204 KB |
Output is correct |
110 |
Correct |
0 ms |
204 KB |
Output is correct |
111 |
Correct |
0 ms |
204 KB |
Output is correct |
112 |
Correct |
0 ms |
204 KB |
Output is correct |
113 |
Correct |
0 ms |
204 KB |
Output is correct |
114 |
Correct |
1 ms |
204 KB |
Output is correct |
115 |
Correct |
0 ms |
204 KB |
Output is correct |
116 |
Correct |
1 ms |
288 KB |
Output is correct |
117 |
Correct |
1 ms |
204 KB |
Output is correct |
118 |
Correct |
0 ms |
204 KB |
Output is correct |
119 |
Correct |
2 ms |
716 KB |
Output is correct |
120 |
Correct |
2 ms |
844 KB |
Output is correct |
121 |
Correct |
278 ms |
33332 KB |
Output is correct |
122 |
Correct |
440 ms |
49076 KB |
Output is correct |
123 |
Correct |
437 ms |
48080 KB |
Output is correct |
124 |
Correct |
1 ms |
204 KB |
Output is correct |
125 |
Correct |
1 ms |
288 KB |
Output is correct |
126 |
Correct |
0 ms |
204 KB |
Output is correct |
127 |
Correct |
594 ms |
68944 KB |
Output is correct |
128 |
Correct |
595 ms |
69496 KB |
Output is correct |
129 |
Correct |
602 ms |
72184 KB |
Output is correct |
130 |
Correct |
5 ms |
1100 KB |
Output is correct |
131 |
Correct |
7 ms |
1740 KB |
Output is correct |
132 |
Correct |
296 ms |
29192 KB |
Output is correct |
133 |
Correct |
461 ms |
47256 KB |
Output is correct |
134 |
Correct |
651 ms |
58652 KB |
Output is correct |
135 |
Correct |
641 ms |
76788 KB |
Output is correct |
136 |
Correct |
629 ms |
65512 KB |
Output is correct |
137 |
Correct |
686 ms |
76964 KB |
Output is correct |
138 |
Correct |
743 ms |
66336 KB |
Output is correct |
139 |
Correct |
622 ms |
56676 KB |
Output is correct |
140 |
Correct |
0 ms |
204 KB |
Output is correct |
141 |
Correct |
91 ms |
9716 KB |
Output is correct |
142 |
Correct |
30 ms |
4808 KB |
Output is correct |
143 |
Correct |
80 ms |
12744 KB |
Output is correct |
144 |
Correct |
143 ms |
20392 KB |
Output is correct |
145 |
Correct |
343 ms |
34128 KB |
Output is correct |
146 |
Correct |
441 ms |
43060 KB |
Output is correct |
147 |
Correct |
544 ms |
51916 KB |
Output is correct |
148 |
Correct |
674 ms |
59792 KB |
Output is correct |
149 |
Correct |
777 ms |
68688 KB |
Output is correct |
150 |
Correct |
666 ms |
70864 KB |
Output is correct |
151 |
Correct |
620 ms |
77088 KB |
Output is correct |
152 |
Correct |
6 ms |
1356 KB |
Output is correct |
153 |
Correct |
10 ms |
1996 KB |
Output is correct |
154 |
Correct |
289 ms |
30236 KB |
Output is correct |
155 |
Correct |
455 ms |
45968 KB |
Output is correct |
156 |
Correct |
698 ms |
61516 KB |
Output is correct |
157 |
Correct |
1 ms |
204 KB |
Output is correct |
158 |
Correct |
0 ms |
292 KB |
Output is correct |
159 |
Correct |
0 ms |
204 KB |
Output is correct |
160 |
Correct |
1 ms |
204 KB |
Output is correct |
161 |
Correct |
904 ms |
77540 KB |
Output is correct |
162 |
Correct |
634 ms |
68956 KB |
Output is correct |
163 |
Correct |
664 ms |
61880 KB |
Output is correct |
164 |
Correct |
657 ms |
60976 KB |
Output is correct |
165 |
Incorrect |
756 ms |
74604 KB |
Tree @(765, 771) appears more than once: for edges on positions 88905 and 90428 |
166 |
Halted |
0 ms |
0 KB |
- |