QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#425280#6502. Disjoint Set Unionegypt_ioi2024_04WA 1ms7784kbC++203.0kb2024-05-30 07:27:452024-05-30 07:27:47

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 0
Wrong Answer
time: 1ms
memory: 7784kb

input:

5
3
1 2 3
2 2 3
4
1 2 3 3
1 1 1 2
5
1 2 3 4 5
2 3 4 5 5
5
1 1 1 1 1
1 2 3 4 5
6
1 2 2 4 5 6
1 1 5 1 4 2

output:

YES
2
1 1 
2 1 2 
YES
11
1 1 
2 1 2 
1 2 
1 3 
1 4 
2 3 2 
1 2 
1 3 
1 4 
2 2 1 
1 3 
YES
25
1 1 
2 1 2 
1 2 
1 3 
1 4 
2 3 2 
1 2 
1 3 
1 4 
2 2 1 
1 3 
1 1 
1 2 
1 3 
1 4 
2 1 2 
1 2 
1 3 
1 4 
2 2 3 
1 3 
1 4 
2 3 4 
1 4 
2 4 5 
NO
YES
49
1 1 
2 1 2 
1 2 
1 3 
1 4 
2 3 2 
1 2 
1 3 
1 4 
2 2 1 
1 ...

result:

wrong answer f[1] = 2, but expected 1 (test case 2)