QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#624978#8759. 小班课ucup-team3475#WA 3ms6140kbC++203.7kb2024-10-09 17:02:542024-10-09 17:02:54

詳細信息

Test #1:

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

input:

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

output:

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

result:

ok Correct!

Test #2:

score: 0
Accepted
time: 1ms
memory: 3876kb

input:

250
2 1
2
1 1
1 1
1 1
1
0
2 2
1 1
1 1
2 2 1
2 2
0 2
2 1 2
1 2
1 1
1
1 1
1 2
1 0
0
1 2
1 0
0
2 1
2
1 1
0
1 2
1 0
0
2 1
2
1 1
1 1
1 1
1
1 1
1 2
1 0
1 2
2 2
2 0
1 1
1 2
1 1
1
0
1 1
1
0
1 2
0 1
1 1
2 2
1 1
1 1
2 1 2
2 2
1 1
2 2 1
2 2 1
1 2
0 1
1 2
2 1
2
1 1
0
2 2
2 0
1 1
1 2
1 1
1
1 1
2 1
2
0
1 1
1 1
1
...

output:

2
1 2 
0
1 
2
1 2 
2
2 1 
1
1 
0
1 
0
1 
1
1 2 
0
1 
2
1 2 
1
1 
0
1 
1
1 2 
0
1 
0
1 
0
1 
2
1 2 
2
1 2 
1
1 
1
1 2 
1
1 2 
1
1 
1
2 1 
1
1 
1
2 1 
0
1 2 
1
1 
1
1 
0
1 
1
1 
2
1 2 
0
1 
0
1 
1
1 2 
2
2 1 
0
1 
0
1 
0
1 
0
1 2 
2
1 2 
1
1 
1
1 
0
1 
0
1 
0
1 
1
1 
1
1 
0
1 
2
1 2 
2
1 2 
1
2 1 
1
1...

result:

ok Correct!

Test #3:

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

input:

166
3 3
1 1 1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 3 13 43 22
0
10 23 46 22 40 12 19 47 27 16 42
4 29 19 45 35
10 6 26 2 43 41 7 9 16 42 44
5 39 40 34 46 14
3 34 3 38
8 10 5 38 23 19 37 9 34
0
5 31 29 15 13 35
3 40 4 28
1 7
6 29 12 9 35 2...

output:

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

result:

ok Correct!

Test #7:

score: -100
Wrong Answer
time: 3ms
memory: 6140kb

input:

1
499 497
1 2 0 2 0 1 0 0 0 2 1 2 0 3 1 2 0 0 0 1 0 1 0 2 1 0 1 0 1 1 1 2 0 1 0 1 0 2 2 3 1 1 2 1 0 0 1 0 2 3 0 1 0 0 2 0 1 2 1 0 0 1 2 0 0 2 0 2 0 1 0 1 0 0 1 0 0 1 1 1 1 1 0 0 0 1 2 3 0 0 0 4 2 2 1 2 2 0 1 0 1 0 2 0 1 0 2 0 0 1 1 1 3 2 0 2 2 2 0 1 1 1 1 1 0 1 0 1 1 1 1 1 2 0 0 1 0 2 1 2 1 2 1 0 1 ...

output:

482
234 31 95 124 126 142 153 167 190 268 347 346 318 401 359 412 410 273 344 27 496 125 353 291 159 324 433 372 67 247 75 329 294 377 287 116 155 53 312 393 222 367 244 38 17 290 10 321 342 52 136 37 485 482 307 492 171 189 143 115 197 491 32 446 345 250 480 383 409 79 462 471 308 46 5 8 92 449 150...

result:

wrong answer wrong rearrangement 481 482