QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#107225#6396. Puzzle: KusabiHuangHanShengWA 25ms7904kbC++112.3kb2023-05-20 16:14:432023-05-20 16:14:46

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 1ms
memory: 5788kb

input:

8
2 1 -
3 1 -
4 2 Tong
5 2 Tong
6 3 Duan
7 3 -
8 7 Chang

output:

YES
5 4
6 8

result:

ok Correct.

Test #2:

score: 0
Accepted
time: 2ms
memory: 5732kb

input:

10
2 1 Duan
3 2 Duan
4 2 -
5 4 Chang
6 2 Chang
7 1 Duan
8 6 Tong
9 6 Tong
10 3 Chang

output:

YES
9 8
7 6
2 5
3 10

result:

ok Correct.

Test #3:

score: 0
Accepted
time: 0ms
memory: 5640kb

input:

2
2 1 Tong

output:

NO

result:

ok Correct.

Test #4:

score: -100
Wrong Answer
time: 25ms
memory: 7904kb

input:

100000
2 1 Duan
3 1 Duan
4 3 -
5 4 Duan
6 3 -
7 4 Duan
8 4 -
9 8 -
10 7 Duan
11 9 -
12 7 Duan
13 7 Duan
14 8 Duan
15 13 -
16 10 Duan
17 11 Duan
18 12 -
19 1 Duan
20 5 Duan
21 4 Duan
22 14 Duan
23 16 -
24 22 Duan
25 16 Duan
26 13 -
27 13 -
28 17 -
29 5 Duan
30 22 -
31 23 -
32 9 Duan
33 5 -
34 30 Duan...

output:

YES
61327 78961
28763 79617
59851 93895
41090 52589
69894 7241
8873 8241
69010 19874
85932 33789
58699 15911
3681 14132
31315 3156
78400 3283
83333 28194
95031 79799
27446 24772
86323 54276
63173 13236
75831 10691
8051 18882
10294 15047
3328 36926
5219 6257
3940 10051
29250 34214
5411 71680
78617 20...

result:

wrong answer Edge 3-1 used twice.