QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#443420#8581. 섬ZhaoZiLong14 57ms12196kbC++232.7kb2024-06-15 15:30:242024-06-15 15:30:28

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 6
Accepted

Test #1:

score: 6
Accepted
time: 1ms
memory: 3792kb

input:

4
0 2

output:

1
4
0 4
4 2
0 1
2 3
2
4
4 1
2 1
0 2
0 3
1
0 2 1

result:

ok Correct

Test #2:

score: 6
Accepted
time: 0ms
memory: 3788kb

input:

3

output:

1
3
0 1
1 3
3 2
2
3
1 2
2 0
0 3
1
0 1 2

result:

ok Correct

Test #3:

score: 6
Accepted
time: 1ms
memory: 4076kb

input:

4
3 1

output:

1
4
1 4
4 3
1 2
3 0
2
4
4 2
3 2
1 3
1 0
1
1 3 2

result:

ok Correct

Test #4:

score: 6
Accepted
time: 0ms
memory: 3884kb

input:

5
1 4
1 3

output:

1
5
0 1
1 2
3 4
4 0
5 1
2
5
2 3
1 4
1 3
5 4
5 0
1
1 4 0

result:

ok Correct

Subtask #2:

score: 8
Accepted

Test #5:

score: 8
Accepted
time: 0ms
memory: 3864kb

input:

10
7 0
7 5
7 3
7 1
7 9
7 4
7 2

output:

1
10
0 1
1 2
2 3
3 4
4 5
5 6
7 8
8 9
9 0
10 9
2
10
7 0
7 5
7 3
7 1
7 9
7 4
7 2
6 7
7 10
8 10
1
7 8 9

result:

ok Correct

Test #6:

score: 8
Accepted
time: 0ms
memory: 3856kb

input:

1000
10 919
10 561
10 671
10 430
10 425
10 987
10 608
10 401
10 467
10 850
10 207
10 99
10 864
10 907
10 590
10 410
10 3
10 236
10 546
10 455
10 694
10 651
10 193
10 295
10 910
10 929
10 151
10 157
10 869
10 453
10 587
10 800
10 988
10 832
10 7
10 723
10 172
10 628
10 432
10 527
10 702
10 328
10 895...

output:

1
1000
0 1
1 2
2 3
3 4
4 5
5 6
6 7
7 8
8 9
10 11
11 12
12 13
13 14
14 15
15 16
16 17
17 18
18 19
19 20
20 21
21 22
22 23
23 24
24 25
25 26
26 27
27 28
28 29
29 30
30 31
31 32
32 33
33 34
34 35
35 36
36 37
37 38
38 39
39 40
40 41
41 42
42 43
43 44
44 45
45 46
46 47
47 48
48 49
49 50
50 51
51 52
52 53...

result:

ok Correct

Test #7:

score: 8
Accepted
time: 2ms
memory: 4296kb

input:

5000
3653 4458
3653 4383
3653 1303
3653 3306
3653 3218
3653 2614
3653 4321
3653 959
3653 2749
3653 3926
3653 3679
3653 2498
3653 163
3653 1980
3653 3542
3653 1300
3653 4388
3653 4971
3653 3012
3653 711
3653 103
3653 3179
3653 4304
3653 4387
3653 1526
3653 4202
3653 3989
3653 810
3653 4756
3653 4029
...

output:

1
5000
0 1
1 2
2 3
3 4
4 5
5 6
6 7
7 8
8 9
9 10
10 11
11 12
12 13
13 14
14 15
15 16
16 17
17 18
18 19
19 20
20 21
21 22
22 23
23 24
24 25
25 26
26 27
27 28
28 29
29 30
30 31
31 32
32 33
33 34
34 35
35 36
36 37
37 38
38 39
39 40
40 41
41 42
42 43
43 44
44 45
45 46
46 47
47 48
48 49
49 50
50 51
51 52
...

result:

ok Correct

Test #8:

score: 8
Accepted
time: 57ms
memory: 12196kb

input:

199999
98281 193703
98281 79970
98281 92443
98281 1621
98281 144687
98281 143302
98281 15416
98281 9245
98281 127092
98281 21325
98281 149110
98281 119923
98281 53885
98281 25820
98281 29852
98281 34700
98281 120142
98281 185421
98281 84923
98281 66458
98281 192051
98281 44169
98281 114692
98281 105...

output:

1
199999
0 1
1 2
2 3
3 4
4 5
5 6
6 7
7 8
8 9
9 10
10 11
11 12
12 13
13 14
14 15
15 16
16 17
17 18
18 19
19 20
20 21
21 22
22 23
23 24
24 25
25 26
26 27
27 28
28 29
29 30
30 31
31 32
32 33
33 34
34 35
35 36
36 37
37 38
38 39
39 40
40 41
41 42
42 43
43 44
44 45
45 46
46 47
47 48
48 49
49 50
50 51
51 5...

result:

ok Correct

Test #9:

score: 8
Accepted
time: 50ms
memory: 11992kb

input:

200000
175608 25000
175608 61359
175608 134288
175608 74838
175608 58154
175608 21892
175608 76830
175608 141171
175608 76397
175608 98232
175608 39276
175608 143602
175608 78284
175608 149754
175608 181632
175608 172252
175608 112871
175608 142010
175608 2821
175608 18165
175608 105580
175608 16460...

output:

1
200000
0 1
1 2
2 3
3 4
4 5
5 6
6 7
7 8
8 9
9 10
10 11
11 12
12 13
13 14
14 15
15 16
16 17
17 18
18 19
19 20
20 21
21 22
22 23
23 24
24 25
25 26
26 27
27 28
28 29
29 30
30 31
31 32
32 33
33 34
34 35
35 36
36 37
37 38
38 39
39 40
40 41
41 42
42 43
43 44
44 45
45 46
46 47
47 48
48 49
49 50
50 51
51 5...

result:

ok Correct

Subtask #3:

score: 0
Wrong Answer

Test #10:

score: 0
Wrong Answer
time: 2ms
memory: 4272kb

input:

5000
4593 3389
4593 1610
4593 2357
4593 3323
4593 2037
4593 3667
4593 2737
4593 2642
4593 3981
4593 2700
4593 2134
4593 1719
4593 1444
4593 3729
4593 1371
4593 546
4593 1249
4593 646
4593 4221
4593 1542
4593 2314
4735 4952
4593 680
4593 2555
4593 2152
4593 740
4593 4056
4593 64
4593 3079
4593 3021
4...

output:

1
5000
0 1
1 2
2 3
3 4
4 5
5 6
6 7
7 8
8 9
9 10
10 11
11 12
12 13
13 14
14 15
15 16
16 17
17 18
18 19
19 20
20 21
21 22
22 23
23 24
24 25
25 26
26 27
27 28
28 29
29 30
30 31
31 32
32 33
33 34
34 35
35 36
36 37
37 38
38 39
39 40
40 41
41 42
42 43
43 44
44 45
45 46
46 47
47 48
48 49
49 50
50 51
51 52
...

result:

wrong answer Wrong Answer, wrong operation

Subtask #4:

score: 0
Wrong Answer

Dependency #1:

100%
Accepted

Test #19:

score: 0
Wrong Answer
time: 0ms
memory: 3880kb

input:

10
0 2
6 0
4 2
0 5
6 9
6 8
0 4

output:

1
10
0 1
1 2
2 3
3 4
4 5
5 6
6 7
7 8
8 9
10 2
2
10
0 2
6 0
4 2
0 5
6 9
6 8
0 4
9 0
0 10
1 10
1
0 1 2

result:

wrong answer Wrong Answer, printed edges do not form a spanning tree

Subtask #5:

score: 0
Skipped

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Dependency #3:

0%