QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#659367#5025. 假期计划Nova_NightWind0311100 ✓206ms10292kbC++201.8kb2024-10-19 19:50:392024-10-19 19:50:40

詳細信息


Pretests


Final Tests

Test #1:

score: 5
Accepted
time: 0ms
memory: 3820kb

input:

7 9 0
100 100 100 200 300 400
1 2
2 3
3 4
1 5
1 6
1 7
5 4
6 4
7 4

output:

700

result:

ok 1 number(s): "700"

Test #2:

score: 5
Accepted
time: 0ms
memory: 4064kb

input:

8 10 0
16 79 10 16 8 32 45
2 6
1 4
3 4
1 7
7 4
8 1
8 3
5 2
2 1
7 5

output:

166

result:

ok 1 number(s): "166"

Test #3:

score: 5
Accepted
time: 0ms
memory: 3848kb

input:

10 15 0
17 11 4 12 27 10 28 20 15
7 10
9 8
4 6
6 3
2 1
8 1
7 8
4 9
3 9
7 1
3 7
10 8
3 2
7 9
8 5

output:

76

result:

ok 1 number(s): "76"

Test #4:

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

input:

8 8 1
901 701 101 801 201 301 601
1 2
2 3
3 4
4 5
5 6
6 7
7 8
8 1

output:

2704

result:

ok 1 number(s): "2704"

Test #5:

score: 5
Accepted
time: 0ms
memory: 4096kb

input:

10 9 5
6 34 30 8 23 183 154 166 170
1 2
2 3
3 4
4 5
5 6
6 7
7 8
8 9
9 10

output:

553

result:

ok 1 number(s): "553"

Test #6:

score: 5
Accepted
time: 0ms
memory: 3844kb

input:

20 19 10
8 54 38 10 19 9 60 34 46 39 44 39 34 29 61 309 270 294 300
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

output:

715

result:

ok 1 number(s): "715"

Test #7:

score: 5
Accepted
time: 1ms
memory: 5852kb

input:

15 20 20
104 118 198 206 93 189 202 146 70 209 116 139 84 224
11 1
1 3
6 2
3 9
9 2
2 5
3 8
2 3
9 10
5 3
10 6
13 14
7 10
9 7
10 1
9 8
12 13
8 11
7 11
9 4

output:

815

result:

ok 1 number(s): "815"

Test #8:

score: 5
Accepted
time: 0ms
memory: 4124kb

input:

20 50 100
8 550 534 134 453 381 370 530 46 473 44 163 468 153 495 743 84 542 919
12 1
8 11
17 18
14 9
13 9
7 1
10 8
3 12
17 19
3 13
4 11
11 12
1 10
20 17
15 4
16 19
13 12
5 8
2 8
3 7
11 13
1 4
11 9
10 12
14 8
6 7
19 20
6 10
6 13
2 10
6 3
11 3
13 15
2 4
2 11
6 9
18 19
3 5
5 6
20 18
8 1
7 2
4 7
10 7
2...

output:

2087

result:

ok 1 number(s): "2087"

Test #9:

score: 5
Accepted
time: 1ms
memory: 4156kb

input:

150 280 0
404 472 438 356 213 705 88 338 46 377 710 697 300 99 579 119 708 314 116 76 473 402 331 678 471 227 528 384 599 473 189 557 391 673 287 710 498 623 572 183 517 247 489 160 500 738 685 156 298 73 493 119 620 674 371 161 612 140 21 231 10 610 517 175 144 667 295 346 409 319 354 323 582 583 4...

output:

2207

result:

ok 1 number(s): "2207"

Test #10:

score: 5
Accepted
time: 3ms
memory: 4568kb

input:

300 760 0
464 142 318 86 813 165 178 458 406 17 620 67 300 609 39 839 108 254 746 556 383 72 361 288 411 557 18 114 809 113 369 647 181 793 677 830 408 263 632 333 457 457 219 130 80 18 295 66 298 703 613 629 320 764 191 191 792 380 381 561 130 580 457 775 684 697 715 16 439 709 294 233 432 343 97 5...

output:

1153

result:

ok 1 number(s): "1153"

Test #11:

score: 5
Accepted
time: 2ms
memory: 4812kb

input:

300 1000 0
544 630 102 766 205 621 402 186 1014 769 740 427 548 457 87 79 172 422 338 804 63 592 617 456 987 357 562 1042 897 177 849 583 949 873 301 1030 128 327 56 845 657 185 891 810 560 346 207 362 482 7 533 549 592 356 551 255 544 716 677 777 418 300 793 871 276 1009 259 840 567 197 854 873 152...

output:

2847

result:

ok 1 number(s): "2847"

Test #12:

score: 5
Accepted
time: 4ms
memory: 4572kb

input:

300 300 100
194 302 38 196 143 195 308 158 46 287 230 287 220 29 309 309 208 294 176 56 173 262 71 48 31 237 148 264 69 113 229 7 111 83 177 310 28 203 22 283 17 77 179 60 60 108 5 296 188 193 103 109 210 134 1 181 82 50 101 231 270 30 207 75 64 187 125 86 149 39 194 243 132 213 227 5 168 146 83 132...

output:

1238

result:

ok 1 number(s): "1238"

Test #13:

score: 5
Accepted
time: 0ms
memory: 4572kb

input:

300 600 20
4 56 15 24 83 80 29 49 36 74 81 69 39 86 42 12 66 46 30 187 217 44 13 75 59 48 70 61 18 77 76 9 32 52 55 52 82 43 2 60 53 230 67 62 52 73 44 68 83 8 64 33 37 3 33 15 23 20 3 65 24 4 12 74 84 34 79 18 78 61 58 45 86 21 1 60 36 74 66 3 19 4 38 51 17 60 30 7 3 56 23 25 65 75 22 34 186 65 67 ...

output:

820

result:

ok 1 number(s): "820"

Test #14:

score: 5
Accepted
time: 4ms
memory: 6256kb

input:

300 1000 31
44 32 14 5 120 59 74 2 90 78 142 26 33 44 28 107 99 50 139 53 148 85 102 143 105 100 89 2 145 92 100 1258 86 135 42 98 21 104 2 87 31 16 26 98 58 2 1 90 24 123 15 131 14 126 9 100 101 48 65 47 155 12 69 1479 43 109 138 69 94 21 3 90 84 153 152 45 143 100 133 114 87 10 61 50 78 2 135 137 ...

output:

5702

result:

ok 1 number(s): "5702"

Test #15:

score: 5
Accepted
time: 70ms
memory: 7892kb

input:

1500 10000 0
17804 30922 31338 51806 11313 2805 46138 3938 41446 3077 13460 25147 30900 19749 45279 30719 49308 6914 41966 39076 16523 7752 1381 21528 24171 42977 51378 47934 18749 40073 17889 33107 16741 3973 20837 16310 48348 1223 39872 30033 217 24097 49239 29710 45200 39438 37435 11406 48298 524...

output:

171504

result:

ok 1 number(s): "171504"

Test #16:

score: 5
Accepted
time: 174ms
memory: 10208kb

input:

2500 7500 0
10204 17222 38538 11606 55813 4805 67238 13738 5046 47077 14160 35247 44000 22249 58179 33519 58108 4914 7466 41776 46423 41052 2681 44528 12271 14477 29378 28434 53249 11973 5389 60807 65641 54773 52137 24810 32348 51623 54972 2733 67717 24697 14039 23710 17500 34338 23835 29206 59398 2...

output:

151399

result:

ok 1 number(s): "151399"

Test #17:

score: 5
Accepted
time: 122ms
memory: 10284kb

input:

2500 10000 0
1252904 55929222 50172438 34136606 22456213 31819205 37421338 32972338 53136046 18220377 47373460 69616947 44800300 66374849 78701079 151119 27543708 74029814 53697866 8159076 7744223 44829152 75391081 193928 8332971 10016477 2371778 79157634 4003849 76401473 4645689 2377807 69501141 77...

output:

275479798

result:

ok 1 number(s): "275479798"

Test #18:

score: 5
Accepted
time: 169ms
memory: 10292kb

input:

2000 10000 100
20344 9942 3958 31166 3333 16965 7178 34338 25326 13177 2580 20227 10940 7329 24679 34719 29788 13974 8026 22676 25583 11552 921 9528 31771 5597 578 21394 2489 22513 19689 23887 23701 36353 7397 12030 35408 33863 24432 13493 1857 6337 3019 25050 25840 28018 3655 4266 17658 6863 16573 ...

output:

158695

result:

ok 1 number(s): "158695"

Test #19:

score: 5
Accepted
time: 206ms
memory: 10276kb

input:

2500 7500 100
3130 5489 1830 5334 6022 3914 6017 3626 4436 1107 64 1653 6233 1628 1566 1512 253 7285 6288 6431 4036 4253 3571 423 2032 3102 1997 4296 6772 6948 5505 1500 5557 119 4866 6043 103 7594 3611 3917 1103 4619 5884 239 504 1770 4469 3992 6512 717 4395 3622 2451 692 1149 7218 3375 4454 6707 2...

output:

71832

result:

ok 1 number(s): "71832"

Test #20:

score: 5
Accepted
time: 197ms
memory: 10256kb

input:

2500 10000 99
1252904 5929222 172438 4136606 2456213 1819205 7421338 2972338 3136046 8220377 7373460 9616947 4800300 6374849 8701079 151119 7543708 4029814 3697866 8159076 7744223 4829152 5391081 193928 8332971 16477 2371778 9157634 4003849 6401473 4645689 2377807 9501141 7502673 3460037 1943710 346...

output:

372743322

result:

ok 1 number(s): "372743322"

Extra Test:

score: 0
Extra Test Passed