QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#778782#9251. Graph Changingucup-team5716#WA 1ms3796kbC++143.2kb2024-11-24 16:14:532024-11-24 16:14:53

Details

Tip: Click on the bar to expand more detailed information

Test #1:

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

input:

5
1 5 3 2 4
1 10 4 2 4
2 10 5 2 4
1 3 2 1 3
1 3 2 1 2

output:

3
2
-1
1
-1

result:

ok 5 lines

Test #2:

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

input:

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

output:

1
-1
-1
-1
-1
-1
1
-1
-1
-1
-1
-1
1
-1
-1
-1
-1
-1
1
-1
-1
-1
-1
-1
1
-1
-1
-1
-1
-1

result:

ok 30 lines

Test #3:

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

input:

90
1 3 1 1 2
1 3 1 1 3
1 3 1 2 3
1 3 2 1 2
1 3 2 1 3
1 3 2 2 3
1 3 3 1 2
1 3 3 1 3
1 3 3 2 3
1 3 4 1 2
1 3 4 1 3
1 3 4 2 3
1 3 5 1 2
1 3 5 1 3
1 3 5 2 3
1 3 6 1 2
1 3 6 1 3
1 3 6 2 3
2 3 1 1 2
2 3 1 1 3
2 3 1 2 3
2 3 2 1 2
2 3 2 1 3
2 3 2 2 3
2 3 3 1 2
2 3 3 1 3
2 3 3 2 3
2 3 4 1 2
2 3 4 1 3
2 3 4 2...

output:

1
1
1
-1
1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
1
1
1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
1
1
1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
1
1
1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
1
1
1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1

result:

ok 90 lines

Test #4:

score: -100
Wrong Answer
time: 1ms
memory: 3712kb

input:

180
1 4 1 1 2
1 4 1 1 3
1 4 1 1 4
1 4 1 2 3
1 4 1 2 4
1 4 1 3 4
1 4 2 1 2
1 4 2 1 3
1 4 2 1 4
1 4 2 2 3
1 4 2 2 4
1 4 2 3 4
1 4 3 1 2
1 4 3 1 3
1 4 3 1 4
1 4 3 2 3
1 4 3 2 4
1 4 3 3 4
1 4 4 1 2
1 4 4 1 3
1 4 4 1 4
1 4 4 2 3
1 4 4 2 4
1 4 4 3 4
1 4 5 1 2
1 4 5 1 3
1 4 5 1 4
1 4 5 2 3
1 4 5 2 4
1 4 5 ...

output:

1
1
1
1
1
1
2
1
1
2
1
2
-1
-1
1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
1
1
1
1
1
1
1
2
3
1
2
1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
1
1
1
1
1
1
2
1
1
2
1
2
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
-1
1
1
1
1
1
1
1...

result:

wrong answer 10th lines differ - expected: '3', found: '2'