QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#667480 | #7159. Candy | ttamx# | 100 ✓ | 18ms | 7720kb | C++14 | 687b | 2024-10-22 23:26:23 | 2024-10-22 23:26:35 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
详细
Subtask #1:
score: 6
Accepted
Test #1:
score: 6
Accepted
time: 1ms
memory: 3788kb
input:
1 1 7 7
output:
0
result:
ok single line: '0'
Test #2:
score: 6
Accepted
time: 1ms
memory: 3772kb
input:
1 1 8 7
output:
NO
result:
ok single line: 'NO'
Test #3:
score: 6
Accepted
time: 0ms
memory: 3792kb
input:
2 1 7 5 6
output:
NO
result:
ok single line: 'NO'
Test #4:
score: 6
Accepted
time: 1ms
memory: 3552kb
input:
2 1 7 7 9
output:
0
result:
ok single line: '0'
Test #5:
score: 6
Accepted
time: 1ms
memory: 3664kb
input:
2 1 7 5 7
output:
1
result:
ok single line: '1'
Test #6:
score: 6
Accepted
time: 1ms
memory: 3524kb
input:
2 2 7 2 4
output:
NO
result:
ok single line: 'NO'
Test #7:
score: 6
Accepted
time: 1ms
memory: 3840kb
input:
2 2 7 3 4
output:
0
result:
ok single line: '0'
Test #8:
score: 6
Accepted
time: 1ms
memory: 3548kb
input:
1 1 100 100
output:
0
result:
ok single line: '0'
Subtask #2:
score: 19
Accepted
Test #9:
score: 19
Accepted
time: 13ms
memory: 5620kb
input:
100 50 50 1 0 1 0 0 0 0 0 0 0 0 1 0 0 0 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 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
output:
1805
result:
ok single line: '1805'
Test #10:
score: 19
Accepted
time: 11ms
memory: 5388kb
input:
100 40 40 1 0 1 0 1 0 0 0 1 1 1 1 0 1 1 0 0 1 1 1 1 1 0 1 1 0 1 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 0 1 0 1 1 1 1 1 1 0 0 0 0 1 1 1 1 0 1 1 1 0 0 0 0 1 0 0 1 0 1 1 0 0 0 1 1 0 0 1 0 1 0 1 0 0 0 0 0 0 0 1 0 0 1 1 1 0
output:
607
result:
ok single line: '607'
Test #11:
score: 19
Accepted
time: 11ms
memory: 5892kb
input:
100 60 60 0 0 1 0 0 0 1 1 0 1 1 0 1 1 0 0 0 1 1 1 1 1 1 1 0 1 0 1 1 1 0 1 0 1 0 0 1 1 0 1 0 1 0 1 0 1 1 1 1 0 0 1 1 1 0 1 1 0 0 1 1 1 1 0 1 1 1 0 1 0 0 1 1 1 1 0 1 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1 0 0 0 0 1 0
output:
1229
result:
ok single line: '1229'
Test #12:
score: 19
Accepted
time: 14ms
memory: 5560kb
input:
100 60 60 0 0 0 1 1 1 1 1 0 0 0 0 1 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 1 0 1 1 0 1 1 0 1 1 1 1 1 0 1 0 1 0 0 1 1 0 0 0 1 0 0 1 1 1 1 1 1 1 0 1 0 1 1 0 1 1 0 0 0 1 1 0 1 1 1 0 0 0 1 1 1 0 0 1 0 1 0 0 1 0 0 1 1 0 0 1
output:
NO
result:
ok single line: 'NO'
Test #13:
score: 19
Accepted
time: 18ms
memory: 7404kb
input:
100 98 47 0 0 0 0 0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 0 0 1 1 0 0 0 1 1 0 0 0 1 1 0 1 0 0 0 0 0 0 1 1 1 0 1 0 0 0 0 1 0 1 0 0 0 0 1 1 1 1 1 1 1 1 0 0 1 1 0 1 0 1 1 1 1 1 0 0 1 1 1 0 1 1 0 0 0 1 0 1 0 1 1 1 0 0
output:
0
result:
ok single line: '0'
Test #14:
score: 19
Accepted
time: 13ms
memory: 5652kb
input:
100 50 33 0 1 0 0 1 1 0 1 1 0 0 1 1 0 1 0 0 1 0 0 1 1 1 0 0 1 1 0 1 1 1 0 1 0 0 1 0 1 0 1 1 0 0 1 0 1 1 1 1 0 0 1 1 1 0 0 0 1 0 0 1 1 1 0 0 0 1 1 1 0 1 0 0 0 0 0 1 0 0 0 0 0 1 0 1 0 0 0 0 0 0 1 1 0 0 0 0 1 1 1
output:
84
result:
ok single line: '84'
Test #15:
score: 19
Accepted
time: 13ms
memory: 5836kb
input:
100 50 40 0 0 1 1 0 0 1 0 0 1 0 0 0 1 1 1 0 1 0 0 1 1 1 0 0 0 1 0 1 0 0 0 0 1 0 1 0 0 1 0 0 0 0 1 1 0 0 0 1 0 1 0 1 0 0 1 1 0 0 0 1 1 0 0 1 1 0 1 1 1 0 0 1 1 1 1 1 0 1 1 1 0 1 1 1 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1
output:
725
result:
ok single line: '725'
Test #16:
score: 19
Accepted
time: 9ms
memory: 5352kb
input:
100 50 60 1 0 0 0 0 1 1 0 1 1 1 0 1 0 0 1 1 0 0 0 1 1 0 1 1 1 1 1 0 0 1 1 0 1 0 0 1 1 1 1 1 1 1 0 0 1 0 0 0 0 1 0 1 1 1 1 1 1 1 1 0 0 1 0 0 1 0 1 0 1 1 1 0 1 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 1 1 0 1 0 1 0 0 1 0 1
output:
NO
result:
ok single line: 'NO'
Test #17:
score: 19
Accepted
time: 17ms
memory: 7384kb
input:
100 90 90 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1
output:
365
result:
ok single line: '365'
Test #18:
score: 19
Accepted
time: 11ms
memory: 6044kb
input:
100 60 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
0
result:
ok single line: '0'
Test #19:
score: 19
Accepted
time: 13ms
memory: 5560kb
input:
100 50 0 0 1 1 0 1 1 0 1 1 1 1 0 0 0 0 0 0 0 0 1 0 0 1 0 1 1 1 1 0 0 1 1 1 0 1 1 0 1 0 1 0 0 1 0 0 1 0 1 0 1 1 0 0 0 0 0 1 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 1 1 1 0 0 1 0 1 1 0 1 1 1 0 1 0 0 1 1 1 1 1 1
output:
0
result:
ok single line: '0'
Test #20:
score: 19
Accepted
time: 12ms
memory: 7168kb
input:
100 90 0 1 0 1 1 1 0 1 1 0 0 1 0 1 1 1 0 0 0 1 0 1 0 0 1 0 0 1 0 0 0 0 1 0 1 0 0 0 0 1 1 1 1 1 1 1 1 1 0 0 1 0 1 1 1 0 1 1 0 0 1 1 0 1 0 1 0 1 0 0 1 0 1 1 1 0 1 0 0 1 0 0 1 0 0 0 0 0 1 1 1 0 1 0 0 0 1 0 1 0 0
output:
0
result:
ok single line: '0'
Test #21:
score: 19
Accepted
time: 3ms
memory: 3688kb
input:
100 10 20 0 0 0 0 0 1 1 0 1 1 0 0 1 0 1 1 1 0 1 0 0 0 1 0 1 0 0 0 0 0 0 0 1 1 0 0 1 0 0 1 1 1 0 1 1 1 1 1 0 1 0 0 1 0 0 1 1 0 1 1 0 1 1 1 1 0 0 1 1 1 1 0 0 1 0 1 1 1 1 0 0 0 0 0 0 0 0 0 1 0 0 1 1 0 0 0 0 1 1 1
output:
NO
result:
ok single line: 'NO'
Test #22:
score: 19
Accepted
time: 13ms
memory: 5308kb
input:
100 50 100000000000 1 1 1 0 1 0 1 1 0 0 0 1 1 1 1 1 0 1 1 1 1 0 0 1 1 1 0 1 0 0 1 0 0 0 0 1 1 0 1 1 0 1 0 0 1 0 1 1 1 0 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 0 0 0 0 1 0 0 1 0 1 0 1 1 0 1 0 1 0 1 0 1 0 0 1 1 1 0
output:
NO
result:
ok single line: 'NO'
Test #23:
score: 19
Accepted
time: 9ms
memory: 5372kb
input:
100 50 8589934595 1 0 0 1 1 1 1 1 0 1 1 1 1 0 0 0 0 0 0 1 0 1 1 0 0 1 1 0 1 1 0 1 1 0 0 1 1 0 0 0 0 1 0 0 0 0 0 1 1 0 1 0 1 1 0 1 1 0 0 1 1 1 1 0 0 1 0 0 0 1 0 1 0 0 1 1 0 0 1 1 0 0 0 1 0 0 0 1 1 0 0 1 0 0 1 1 0 1 0 0
output:
NO
result:
ok single line: 'NO'
Subtask #3:
score: 16
Accepted
Dependency #1:
100%
Accepted
Test #24:
score: 16
Accepted
time: 0ms
memory: 3552kb
input:
1 1 7 7
output:
0
result:
ok single line: '0'
Test #25:
score: 16
Accepted
time: 0ms
memory: 3648kb
input:
1 1 8 7
output:
NO
result:
ok single line: 'NO'
Test #26:
score: 16
Accepted
time: 0ms
memory: 3616kb
input:
2 1 7 5 6
output:
NO
result:
ok single line: 'NO'
Test #27:
score: 16
Accepted
time: 1ms
memory: 3608kb
input:
2 1 7 7 9
output:
0
result:
ok single line: '0'
Test #28:
score: 16
Accepted
time: 0ms
memory: 3836kb
input:
2 1 7 5 7
output:
1
result:
ok single line: '1'
Test #29:
score: 16
Accepted
time: 0ms
memory: 3532kb
input:
2 2 7 2 4
output:
NO
result:
ok single line: 'NO'
Test #30:
score: 16
Accepted
time: 0ms
memory: 3768kb
input:
2 2 7 3 4
output:
0
result:
ok single line: '0'
Test #31:
score: 16
Accepted
time: 0ms
memory: 3644kb
input:
3 1 7 4 5 6
output:
NO
result:
ok single line: 'NO'
Test #32:
score: 16
Accepted
time: 0ms
memory: 3644kb
input:
3 1 7 4 5 7
output:
2
result:
ok single line: '2'
Test #33:
score: 16
Accepted
time: 0ms
memory: 3768kb
input:
3 1 7 4 8 7
output:
1
result:
ok single line: '1'
Test #34:
score: 16
Accepted
time: 0ms
memory: 3536kb
input:
3 1 7 7 3 9
output:
0
result:
ok single line: '0'
Test #35:
score: 16
Accepted
time: 0ms
memory: 3552kb
input:
3 2 7 3 3 3
output:
NO
result:
ok single line: 'NO'
Test #36:
score: 16
Accepted
time: 0ms
memory: 3524kb
input:
3 2 7 2 3 4
output:
2
result:
ok single line: '2'
Test #37:
score: 16
Accepted
time: 1ms
memory: 3616kb
input:
3 2 7 3 2 4
output:
1
result:
ok single line: '1'
Test #38:
score: 16
Accepted
time: 1ms
memory: 3580kb
input:
3 2 7 4 5 6
output:
0
result:
ok single line: '0'
Test #39:
score: 16
Accepted
time: 0ms
memory: 3544kb
input:
3 3 7 1 3 2
output:
NO
result:
ok single line: 'NO'
Test #40:
score: 16
Accepted
time: 0ms
memory: 3636kb
input:
3 3 7 3 1 3
output:
0
result:
ok single line: '0'
Test #41:
score: 16
Accepted
time: 1ms
memory: 3532kb
input:
3 2 0 0 0 0
output:
0
result:
ok single line: '0'
Test #42:
score: 16
Accepted
time: 0ms
memory: 3844kb
input:
3 2 0 1 2 3
output:
0
result:
ok single line: '0'
Test #43:
score: 16
Accepted
time: 0ms
memory: 3624kb
input:
20 10 6566144533 323906753 73234 169258261 146483217 2526483 50563297 7173957 419870302 86885946 277634715 748939350 422834669 440114820 504900304 648304476 630339210 900877811 593594945 953548400 722690548
output:
100
result:
ok single line: '100'
Test #44:
score: 16
Accepted
time: 0ms
memory: 3844kb
input:
20 10 6164244072 155183169 228236990 208003086 343519393 203430078 129307145 158643368 33100189 235687056 222657550 413967161 896436020 887689465 550380926 691043319 946504501 444961305 475841383 388568669 468851323
output:
100
result:
ok single line: '100'
Test #45:
score: 16
Accepted
time: 1ms
memory: 3612kb
input:
20 18 9610913809 58382570 1322710 654840381 202842775 300914313 462981306 141101410 670033653 737028856 888310178 420221248 393987230 214258398 897791395 261977352 762131762 938005468 558347054 363867624 742273406
output:
36
result:
ok single line: '36'
Test #46:
score: 16
Accepted
time: 1ms
memory: 3628kb
input:
20 8 8000000000 1000000000 999999999 1000000000 1000000000 999999999 999999999 999999999 1000000000 1000000000 999999999 1000000000 1000000000 999999999 999999999 999999999 1000000000 999999999 1000000000 999999999 1000000000
output:
28
result:
ok single line: '28'
Test #47:
score: 16
Accepted
time: 0ms
memory: 3612kb
input:
20 12 12000000000 1000000000 1000000000 999999999 999999999 1000000000 999999999 1000000000 999999999 999999999 1000000000 1000000000 999999999 1000000000 999999999 999999999 1000000000 1000000000 1000000000 1000000000 1000000000
output:
61
result:
ok single line: '61'
Test #48:
score: 16
Accepted
time: 0ms
memory: 3848kb
input:
20 12 12000000000 999999999 999999999 999999999 999999999 1000000000 999999999 1000000000 999999999 1000000000 1000000000 1000000000 1000000000 1000000000 999999999 1000000000 999999999 1000000000 1000000000 1000000000 999999999
output:
NO
result:
ok single line: 'NO'
Test #49:
score: 16
Accepted
time: 1ms
memory: 3628kb
input:
20 10 3333333333 263624178 602898190 420963433 437884997 29710349 491478505 762760712 223384385 55154427 247361461 311280665 796832434 325014303 418646560 443155385 309305851 287458918 290458843 73509473 381919309
output:
0
result:
ok single line: '0'
Test #50:
score: 16
Accepted
time: 1ms
memory: 3564kb
input:
20 10 6800000000 6727977 168476741 640453099 745909210 465912066 597929442 309004415 752756925 512558999 407756549 699491803 550336604 928590530 509682749 930053726 972170609 830489125 317341090 602598601 786818691
output:
28
result:
ok single line: '28'
Test #51:
score: 16
Accepted
time: 1ms
memory: 3616kb
input:
20 10 8400000000 490759429 577739494 777938828 26684416 983875443 660699290 311443997 945777950 948498829 437718566 114473495 420625153 506020763 85582893 767427548 976050679 783422475 168447458 633031695 182488951
output:
NO
result:
ok single line: 'NO'
Test #52:
score: 16
Accepted
time: 0ms
memory: 3840kb
input:
20 10 3000000000 132894078 60976811 122272635 118825862 344797520 499759987 416983334 464948474 332856593 716815545 587427340 521430452 580842697 777336152 740614865 773332159 910211548 760580366 872763270 862088305
output:
0
result:
ok single line: '0'
Test #53:
score: 16
Accepted
time: 0ms
memory: 3612kb
input:
20 10 4000000000 201987269 198126981 158756144 188296059 182086700 262863090 543395895 372218384 432780571 419887028 510659429 556696166 384624599 668282669 672913794 605220743 692335425 477735221 622621736 842880145
output:
21
result:
ok single line: '21'
Test #54:
score: 16
Accepted
time: 0ms
memory: 3836kb
input:
20 10 5000000000 144425144 110530990 359934042 0 400143548 443138967 331050017 638875702 268160577 558102915 551357335 724461476 658896595 662039701 706213909 756666187 789234319 631704115 935768714 876353223
output:
26
result:
ok single line: '26'
Test #55:
score: 16
Accepted
time: 1ms
memory: 3628kb
input:
20 10 6000000000 240858929 20956451 271016582 198575969 414187671 287687480 267328642 166255826 612041111 742856091 544779310 462660138 721565200 712987358 613477373 861977305 772887187 754803381 751790051 806510817
output:
51
result:
ok single line: '51'
Test #56:
score: 16
Accepted
time: 1ms
memory: 3624kb
input:
20 10 7000000000 72400301 253293083 88322729 203869372 305687730 15909565 444043421 507401475 548666163 495533730 479026621 615617352 677540315 756907917 753695398 609838578 887405794 651243868 791919978 907717036
output:
88
result:
ok single line: '88'
Test #57:
score: 16
Accepted
time: 1ms
memory: 3600kb
input:
20 10 8000000000 239757482 257154616 26372785 260661934 255928849 390775920 305428517 432319097 334310334 398076038 518978541 494543443 527856458 736609886 858915291 753585415 832823371 804815588 905429868 846897833
output:
NO
result:
ok single line: 'NO'
Test #58:
score: 16
Accepted
time: 0ms
memory: 3876kb
input:
20 18 9400000000 233234959 239533200 196553166 246868328 201443657 349435478 348192133 296370133 507063613 437055050 375561412 669201134 621129480 598775583 518467201 737587081 757134181 924422699 821116542 1000000000
output:
20
result:
ok single line: '20'
Test #59:
score: 16
Accepted
time: 1ms
memory: 3624kb
input:
20 18 18000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 999999999 1000000000 1000000000 1000000000 999999999 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000
output:
21
result:
ok single line: '21'
Test #60:
score: 16
Accepted
time: 0ms
memory: 3636kb
input:
5 5 123123123 1000000000 1000000000 0 0 0
output:
0
result:
ok single line: '0'
Test #61:
score: 16
Accepted
time: 0ms
memory: 3820kb
input:
6 2 27 10 4 20 6 3 3
output:
1
result:
ok single line: '1'
Test #62:
score: 16
Accepted
time: 1ms
memory: 3824kb
input:
6 5 5000000000 1000000000 1000000000 0 1000000000 1000000000 1000000000
output:
3
result:
ok single line: '3'
Test #63:
score: 16
Accepted
time: 0ms
memory: 3524kb
input:
3 2 100 20 30 60
output:
NO
result:
ok single line: 'NO'
Test #64:
score: 16
Accepted
time: 1ms
memory: 3604kb
input:
1 1 100 100
output:
0
result:
ok single line: '0'
Subtask #4:
score: 30
Accepted
Dependency #1:
100%
Accepted
Dependency #2:
100%
Accepted
Test #65:
score: 30
Accepted
time: 0ms
memory: 3828kb
input:
1 1 7 7
output:
0
result:
ok single line: '0'
Test #66:
score: 30
Accepted
time: 0ms
memory: 3844kb
input:
1 1 8 7
output:
NO
result:
ok single line: 'NO'
Test #67:
score: 30
Accepted
time: 0ms
memory: 3520kb
input:
2 1 7 5 6
output:
NO
result:
ok single line: 'NO'
Test #68:
score: 30
Accepted
time: 0ms
memory: 3548kb
input:
2 1 7 7 9
output:
0
result:
ok single line: '0'
Test #69:
score: 30
Accepted
time: 0ms
memory: 3636kb
input:
2 1 7 5 7
output:
1
result:
ok single line: '1'
Test #70:
score: 30
Accepted
time: 0ms
memory: 3552kb
input:
2 2 7 2 4
output:
NO
result:
ok single line: 'NO'
Test #71:
score: 30
Accepted
time: 0ms
memory: 3580kb
input:
2 2 7 3 4
output:
0
result:
ok single line: '0'
Test #72:
score: 30
Accepted
time: 13ms
memory: 5784kb
input:
100 50 50 1 0 1 0 0 0 0 0 0 0 0 1 0 0 0 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 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
output:
1805
result:
ok single line: '1805'
Test #73:
score: 30
Accepted
time: 11ms
memory: 5208kb
input:
100 40 40 1 0 1 0 1 0 0 0 1 1 1 1 0 1 1 0 0 1 1 1 1 1 0 1 1 0 1 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 0 1 0 1 1 1 1 1 1 0 0 0 0 1 1 1 1 0 1 1 1 0 0 0 0 1 0 0 1 0 1 1 0 0 0 1 1 0 0 1 0 1 0 1 0 0 0 0 0 0 0 1 0 0 1 1 1 0
output:
607
result:
ok single line: '607'
Test #74:
score: 30
Accepted
time: 14ms
memory: 6196kb
input:
100 60 60 0 0 1 0 0 0 1 1 0 1 1 0 1 1 0 0 0 1 1 1 1 1 1 1 0 1 0 1 1 1 0 1 0 1 0 0 1 1 0 1 0 1 0 1 0 1 1 1 1 0 0 1 1 1 0 1 1 0 0 1 1 1 1 0 1 1 1 0 1 0 0 1 1 1 1 0 1 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1 0 0 0 0 1 0
output:
1229
result:
ok single line: '1229'
Test #75:
score: 30
Accepted
time: 11ms
memory: 5416kb
input:
100 60 60 0 0 0 1 1 1 1 1 0 0 0 0 1 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 1 0 1 1 0 1 1 0 1 1 1 1 1 0 1 0 1 0 0 1 1 0 0 0 1 0 0 1 1 1 1 1 1 1 0 1 0 1 1 0 1 1 0 0 0 1 1 0 1 1 1 0 0 0 1 1 1 0 0 1 0 1 0 0 1 0 0 1 1 0 0 1
output:
NO
result:
ok single line: 'NO'
Test #76:
score: 30
Accepted
time: 17ms
memory: 7720kb
input:
100 98 47 0 0 0 0 0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 0 0 1 1 0 0 0 1 1 0 0 0 1 1 0 1 0 0 0 0 0 0 1 1 1 0 1 0 0 0 0 1 0 1 0 0 0 0 1 1 1 1 1 1 1 1 0 0 1 1 0 1 0 1 1 1 1 1 0 0 1 1 1 0 1 1 0 0 0 1 0 1 0 1 1 1 0 0
output:
0
result:
ok single line: '0'
Test #77:
score: 30
Accepted
time: 13ms
memory: 5612kb
input:
100 50 33 0 1 0 0 1 1 0 1 1 0 0 1 1 0 1 0 0 1 0 0 1 1 1 0 0 1 1 0 1 1 1 0 1 0 0 1 0 1 0 1 1 0 0 1 0 1 1 1 1 0 0 1 1 1 0 0 0 1 0 0 1 1 1 0 0 0 1 1 1 0 1 0 0 0 0 0 1 0 0 0 0 0 1 0 1 0 0 0 0 0 0 1 1 0 0 0 0 1 1 1
output:
84
result:
ok single line: '84'
Test #78:
score: 30
Accepted
time: 13ms
memory: 5508kb
input:
100 50 40 0 0 1 1 0 0 1 0 0 1 0 0 0 1 1 1 0 1 0 0 1 1 1 0 0 0 1 0 1 0 0 0 0 1 0 1 0 0 1 0 0 0 0 1 1 0 0 0 1 0 1 0 1 0 0 1 1 0 0 0 1 1 0 0 1 1 0 1 1 1 0 0 1 1 1 1 1 0 1 1 1 0 1 1 1 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1
output:
725
result:
ok single line: '725'
Test #79:
score: 30
Accepted
time: 8ms
memory: 5196kb
input:
100 50 60 1 0 0 0 0 1 1 0 1 1 1 0 1 0 0 1 1 0 0 0 1 1 0 1 1 1 1 1 0 0 1 1 0 1 0 0 1 1 1 1 1 1 1 0 0 1 0 0 0 0 1 0 1 1 1 1 1 1 1 1 0 0 1 0 0 1 0 1 0 1 1 1 0 1 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 1 1 0 1 0 1 0 0 1 0 1
output:
NO
result:
ok single line: 'NO'
Test #80:
score: 30
Accepted
time: 13ms
memory: 7064kb
input:
100 90 90 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1
output:
365
result:
ok single line: '365'
Test #81:
score: 30
Accepted
time: 14ms
memory: 5976kb
input:
100 60 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
0
result:
ok single line: '0'
Test #82:
score: 30
Accepted
time: 8ms
memory: 5856kb
input:
100 50 0 0 1 1 0 1 1 0 1 1 1 1 0 0 0 0 0 0 0 0 1 0 0 1 0 1 1 1 1 0 0 1 1 1 0 1 1 0 1 0 1 0 0 1 0 0 1 0 1 0 1 1 0 0 0 0 0 1 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 1 1 1 0 0 1 0 1 1 0 1 1 1 0 1 0 0 1 1 1 1 1 1
output:
0
result:
ok single line: '0'
Test #83:
score: 30
Accepted
time: 16ms
memory: 7108kb
input:
100 90 0 1 0 1 1 1 0 1 1 0 0 1 0 1 1 1 0 0 0 1 0 1 0 0 1 0 0 1 0 0 0 0 1 0 1 0 0 0 0 1 1 1 1 1 1 1 1 1 0 0 1 0 1 1 1 0 1 1 0 0 1 1 0 1 0 1 0 1 0 0 1 0 1 1 1 0 1 0 0 1 0 0 1 0 0 0 0 0 1 1 1 0 1 0 0 0 1 0 1 0 0
output:
0
result:
ok single line: '0'
Test #84:
score: 30
Accepted
time: 0ms
memory: 3964kb
input:
100 10 20 0 0 0 0 0 1 1 0 1 1 0 0 1 0 1 1 1 0 1 0 0 0 1 0 1 0 0 0 0 0 0 0 1 1 0 0 1 0 0 1 1 1 0 1 1 1 1 1 0 1 0 0 1 0 0 1 1 0 1 1 0 1 1 1 1 0 0 1 1 1 1 0 0 1 0 1 1 1 1 0 0 0 0 0 0 0 0 0 1 0 0 1 1 0 0 0 0 1 1 1
output:
NO
result:
ok single line: 'NO'
Test #85:
score: 30
Accepted
time: 12ms
memory: 5140kb
input:
100 50 100000000000 1 1 1 0 1 0 1 1 0 0 0 1 1 1 1 1 0 1 1 1 1 0 0 1 1 1 0 1 0 0 1 0 0 0 0 1 1 0 1 1 0 1 0 0 1 0 1 1 1 0 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 0 0 0 0 1 0 0 1 0 1 0 1 1 0 1 0 1 0 1 0 1 0 0 1 1 1 0
output:
NO
result:
ok single line: 'NO'
Test #86:
score: 30
Accepted
time: 12ms
memory: 5168kb
input:
100 50 8589934595 1 0 0 1 1 1 1 1 0 1 1 1 1 0 0 0 0 0 0 1 0 1 1 0 0 1 1 0 1 1 0 1 1 0 0 1 1 0 0 0 0 1 0 0 0 0 0 1 1 0 1 0 1 1 0 1 1 0 0 1 1 1 1 0 0 1 0 0 0 1 0 1 0 0 1 1 0 0 1 1 0 0 0 1 0 0 0 1 1 0 0 1 0 0 1 1 0 1 0 0
output:
NO
result:
ok single line: 'NO'
Test #87:
score: 30
Accepted
time: 8ms
memory: 5624kb
input:
100 50 3621 24 39 10 12 22 36 39 0 2 30 33 24 14 36 3 30 20 10 34 28 29 41 1 20 19 26 29 37 4 31 27 36 8 3 25 24 11 36 4 14 25 31 25 35 34 16 36 23 25 30 58 63 85 90 88 72 54 55 47 83 57 51 52 93 45 48 76 68 78 100 71 87 60 72 90 71 61 97 66 63 78 42 89 93 80 86 93 73 88 52 44 76 87 63 100 77 87 81 ...
output:
2500
result:
ok single line: '2500'
Test #88:
score: 30
Accepted
time: 13ms
memory: 5532kb
input:
100 50 3676 23 8 17 28 35 0 22 36 7 35 36 4 34 40 19 27 2 7 11 16 28 7 26 23 26 12 15 41 10 21 29 10 6 32 14 14 35 31 43 22 42 0 44 30 3 50 26 16 24 35 84 99 86 82 52 84 80 57 64 54 64 98 87 56 77 77 98 62 91 64 54 74 63 94 68 65 59 65 92 99 55 61 56 74 52 57 73 88 92 95 69 53 67 90 85 60 57 86 60 97
output:
2500
result:
ok single line: '2500'
Test #89:
score: 30
Accepted
time: 16ms
memory: 7396kb
input:
100 98 4937 2 0 36 15 56 28 90 5 67 80 48 9 33 33 14 34 67 75 87 28 82 83 96 24 70 37 43 16 96 95 91 24 69 22 57 28 43 38 44 73 24 93 16 100 71 32 39 23 56 19 70 30 70 78 57 13 55 82 67 86 6 37 60 73 41 56 23 24 54 91 85 15 68 90 26 67 27 45 37 13 27 33 49 75 85 31 26 48 12 74 98 11 3 15 76 23 97 54...
output:
196
result:
ok single line: '196'
Test #90:
score: 30
Accepted
time: 7ms
memory: 5236kb
input:
100 40 4000 99 100 99 99 99 99 100 100 100 100 99 99 99 99 100 99 99 99 99 100 100 100 99 100 99 100 100 100 100 99 99 100 99 99 99 99 100 100 100 99 99 99 99 99 99 100 99 100 99 100 100 100 99 99 99 100 100 100 100 99 100 99 99 99 99 100 100 99 100 100 100 100 99 99 100 100 99 100 99 100 100 100 10...
output:
999
result:
ok single line: '999'
Test #91:
score: 30
Accepted
time: 14ms
memory: 5896kb
input:
100 60 6000 100 100 100 100 100 99 100 100 99 99 100 100 99 100 100 100 99 100 99 99 99 100 100 100 100 100 100 100 100 100 100 99 100 100 99 100 100 100 99 99 100 100 99 100 100 99 100 100 99 99 100 99 99 100 99 100 99 100 100 99 99 99 100 100 99 100 100 100 100 100 100 100 99 100 100 99 100 99 100...
output:
887
result:
ok single line: '887'
Test #92:
score: 30
Accepted
time: 13ms
memory: 5476kb
input:
100 60 6000 99 99 99 99 100 99 99 100 100 99 100 99 100 99 100 100 99 99 99 100 99 100 99 100 99 100 99 99 99 99 99 99 100 99 99 99 99 99 100 99 100 100 99 100 100 100 100 99 100 99 100 100 100 99 99 100 99 100 100 100 99 100 100 100 100 100 100 100 100 100 100 100 99 100 99 99 100 99 100 100 100 99...
output:
NO
result:
ok single line: 'NO'
Test #93:
score: 30
Accepted
time: 12ms
memory: 5532kb
input:
100 50 1666 12 30 25 26 66 14 52 26 47 7 77 12 68 100 89 38 43 74 48 99 88 28 54 31 21 39 23 77 3 18 78 35 1 4 93 43 90 98 10 59 93 93 81 3 37 22 68 66 77 32 30 19 98 99 66 62 19 12 49 95 75 96 15 42 27 42 95 100 10 0 2 82 3 74 58 54 66 65 70 35 68 17 3 76 14 22 77 34 7 94 90 1 23 8 94 9 22 76 16 58
output:
0
result:
ok single line: '0'
Test #94:
score: 30
Accepted
time: 12ms
memory: 5808kb
input:
100 50 3400 93 69 6 55 88 45 99 26 89 90 35 21 94 1 35 73 95 90 78 22 50 2 79 28 4 81 56 22 8 40 25 37 15 12 10 23 38 71 80 2 58 30 63 97 41 38 42 58 89 23 72 74 39 12 92 45 19 72 71 3 96 71 28 38 84 2 94 87 71 16 1 47 22 45 71 35 92 8 41 86 51 27 14 14 89 93 37 73 12 81 49 36 25 33 75 94 79 37 25 25
output:
477
result:
ok single line: '477'
Test #95:
score: 30
Accepted
time: 12ms
memory: 5164kb
input:
100 50 4200 12 24 3 74 72 71 27 71 26 66 1 35 47 21 84 73 2 99 80 96 19 2 56 83 16 61 68 62 24 52 94 37 50 73 80 13 79 14 74 15 99 88 57 42 79 41 43 61 50 2 31 19 47 66 56 72 63 52 37 55 42 80 79 82 99 25 10 4 70 87 54 54 85 21 80 79 90 76 58 88 43 72 40 78 82 27 60 18 97 21 10 80 17 3 48 1 48 31 10...
output:
NO
result:
ok single line: 'NO'
Test #96:
score: 30
Accepted
time: 12ms
memory: 5652kb
input:
100 50 1500 8 0 21 17 5 11 8 0 25 19 17 35 13 15 24 34 20 25 36 12 24 12 19 20 24 24 50 21 29 26 36 10 28 32 24 33 37 39 37 29 43 27 38 45 62 40 42 40 42 55 65 53 75 37 56 45 43 60 48 45 79 53 55 41 70 74 38 73 73 68 58 87 74 68 57 64 61 66 62 86 55 75 88 69 87 67 80 97 74 80 84 68 76 76 99 91 95 69...
output:
54
result:
ok single line: '54'
Test #97:
score: 30
Accepted
time: 8ms
memory: 5532kb
input:
100 50 2000 22 3 13 20 19 0 9 13 7 5 19 17 18 0 43 21 29 27 23 15 34 27 32 40 34 22 28 26 31 49 26 35 38 28 21 35 20 46 74 46 49 37 34 48 37 43 56 53 33 44 56 60 52 40 49 55 50 70 65 56 60 71 54 74 59 55 53 58 71 62 57 85 78 66 59 72 54 73 64 71 88 79 69 75 80 72 90 72 82 75 89 82 85 90 98 88 85 91 ...
output:
363
result:
ok single line: '363'
Test #98:
score: 30
Accepted
time: 12ms
memory: 5536kb
input:
100 50 2500 20 15 4 13 21 0 10 17 17 8 28 0 21 28 18 11 7 30 0 18 21 8 33 32 22 30 24 24 36 22 34 39 42 44 44 39 45 47 26 42 46 49 36 55 48 21 42 59 53 52 41 52 47 41 53 74 55 43 52 65 57 58 82 52 55 60 57 77 63 86 70 62 65 53 81 88 69 95 77 86 84 83 81 72 66 75 97 82 87 76 91 84 87 75 98 86 78 94 9...
output:
840
result:
ok single line: '840'
Test #99:
score: 30
Accepted
time: 12ms
memory: 5532kb
input:
100 50 3000 17 0 3 17 22 18 12 0 0 7 49 11 29 11 34 24 28 19 23 20 24 39 16 37 31 18 26 28 32 32 33 40 30 40 43 46 38 34 40 40 36 50 49 40 43 30 39 61 44 43 46 39 56 61 43 68 69 47 62 67 61 54 52 52 77 63 61 67 48 83 73 67 63 62 100 82 77 82 71 82 73 74 83 73 91 69 70 62 80 88 78 79 100 90 100 94 90...
output:
1382
result:
ok single line: '1382'
Test #100:
score: 30
Accepted
time: 12ms
memory: 5512kb
input:
100 50 3500 15 5 24 11 15 19 31 10 6 13 17 26 13 11 13 12 38 29 34 25 30 34 13 46 27 30 15 31 36 25 39 19 24 37 23 45 45 31 38 56 42 40 46 38 38 47 50 57 37 51 49 58 51 34 60 51 55 37 72 61 49 71 62 66 69 34 47 76 76 54 65 69 55 88 68 71 55 80 79 91 74 68 81 83 85 73 73 84 81 77 91 82 81 87 82 95 77...
output:
2243
result:
ok single line: '2243'
Test #101:
score: 30
Accepted
time: 8ms
memory: 5304kb
input:
100 50 4000 17 10 26 6 1 20 7 0 10 11 11 29 21 29 32 33 7 35 30 42 20 21 14 28 23 36 45 56 32 21 44 34 28 29 45 47 34 33 35 43 51 41 49 37 34 43 41 61 54 56 40 56 57 70 32 43 61 55 72 56 78 61 61 63 65 63 73 63 68 83 81 82 57 62 67 59 69 66 68 84 86 69 72 63 66 80 77 87 88 68 84 78 74 100 93 75 89 9...
output:
NO
result:
ok single line: 'NO'
Test #102:
score: 30
Accepted
time: 16ms
memory: 7172kb
input:
100 90 4700 15 24 0 4 5 7 17 26 18 33 25 39 12 32 14 10 9 14 8 14 31 19 28 14 33 21 27 39 21 33 40 45 46 49 26 49 20 44 41 37 47 38 43 56 45 46 44 56 54 37 73 48 49 51 71 69 47 70 64 66 65 70 52 78 51 76 44 67 53 75 67 71 74 58 64 84 77 69 73 74 64 74 69 82 82 68 89 81 79 89 83 75 72 64 88 86 81 83 ...
output:
532
result:
ok single line: '532'
Test #103:
score: 30
Accepted
time: 16ms
memory: 7156kb
input:
100 90 9000 100 100 100 100 100 100 100 100 99 100 100 100 100 100 100 100 100 100 99 100 99 100 100 100 100 99 100 99 99 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 99 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100...
output:
498
result:
ok single line: '498'
Test #104:
score: 30
Accepted
time: 0ms
memory: 3548kb
input:
6 2 27 10 4 20 6 3 3
output:
1
result:
ok single line: '1'
Test #105:
score: 30
Accepted
time: 0ms
memory: 3544kb
input:
1 1 100 100
output:
0
result:
ok single line: '0'
Subtask #5:
score: 29
Accepted
Dependency #1:
100%
Accepted
Dependency #2:
100%
Accepted
Dependency #3:
100%
Accepted
Dependency #4:
100%
Accepted
Test #106:
score: 29
Accepted
time: 0ms
memory: 3548kb
input:
1 1 7 7
output:
0
result:
ok single line: '0'
Test #107:
score: 29
Accepted
time: 0ms
memory: 3544kb
input:
1 1 8 7
output:
NO
result:
ok single line: 'NO'
Test #108:
score: 29
Accepted
time: 0ms
memory: 3528kb
input:
2 1 7 5 6
output:
NO
result:
ok single line: 'NO'
Test #109:
score: 29
Accepted
time: 0ms
memory: 3552kb
input:
2 1 7 7 9
output:
0
result:
ok single line: '0'
Test #110:
score: 29
Accepted
time: 0ms
memory: 3524kb
input:
2 1 7 5 7
output:
1
result:
ok single line: '1'
Test #111:
score: 29
Accepted
time: 0ms
memory: 3852kb
input:
2 2 7 2 4
output:
NO
result:
ok single line: 'NO'
Test #112:
score: 29
Accepted
time: 0ms
memory: 3600kb
input:
2 2 7 3 4
output:
0
result:
ok single line: '0'
Test #113:
score: 29
Accepted
time: 9ms
memory: 5836kb
input:
100 50 50 1 0 1 0 0 0 0 0 0 0 0 1 0 0 0 1 1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 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
output:
1805
result:
ok single line: '1805'
Test #114:
score: 29
Accepted
time: 10ms
memory: 5152kb
input:
100 40 40 1 0 1 0 1 0 0 0 1 1 1 1 0 1 1 0 0 1 1 1 1 1 0 1 1 0 1 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 0 1 0 1 1 1 1 1 1 0 0 0 0 1 1 1 1 0 1 1 1 0 0 0 0 1 0 0 1 0 1 1 0 0 0 1 1 0 0 1 0 1 0 1 0 0 0 0 0 0 0 1 0 0 1 1 1 0
output:
607
result:
ok single line: '607'
Test #115:
score: 29
Accepted
time: 10ms
memory: 5940kb
input:
100 60 60 0 0 1 0 0 0 1 1 0 1 1 0 1 1 0 0 0 1 1 1 1 1 1 1 0 1 0 1 1 1 0 1 0 1 0 0 1 1 0 1 0 1 0 1 0 1 1 1 1 0 0 1 1 1 0 1 1 0 0 1 1 1 1 0 1 1 1 0 1 0 0 1 1 1 1 0 1 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1 0 0 0 0 1 0
output:
1229
result:
ok single line: '1229'
Test #116:
score: 29
Accepted
time: 14ms
memory: 5568kb
input:
100 60 60 0 0 0 1 1 1 1 1 0 0 0 0 1 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 1 0 1 1 0 1 1 0 1 1 1 1 1 0 1 0 1 0 0 1 1 0 0 0 1 0 0 1 1 1 1 1 1 1 0 1 0 1 1 0 1 1 0 0 0 1 1 0 1 1 1 0 0 0 1 1 1 0 0 1 0 1 0 0 1 0 0 1 1 0 0 1
output:
NO
result:
ok single line: 'NO'
Test #117:
score: 29
Accepted
time: 13ms
memory: 7516kb
input:
100 98 47 0 0 0 0 0 1 1 1 0 1 1 0 0 1 0 1 0 1 0 0 0 0 0 0 1 1 0 0 0 1 1 0 0 0 1 1 0 1 0 0 0 0 0 0 1 1 1 0 1 0 0 0 0 1 0 1 0 0 0 0 1 1 1 1 1 1 1 1 0 0 1 1 0 1 0 1 1 1 1 1 0 0 1 1 1 0 1 1 0 0 0 1 0 1 0 1 1 1 0 0
output:
0
result:
ok single line: '0'
Test #118:
score: 29
Accepted
time: 12ms
memory: 5620kb
input:
100 50 33 0 1 0 0 1 1 0 1 1 0 0 1 1 0 1 0 0 1 0 0 1 1 1 0 0 1 1 0 1 1 1 0 1 0 0 1 0 1 0 1 1 0 0 1 0 1 1 1 1 0 0 1 1 1 0 0 0 1 0 0 1 1 1 0 0 0 1 1 1 0 1 0 0 0 0 0 1 0 0 0 0 0 1 0 1 0 0 0 0 0 0 1 1 0 0 0 0 1 1 1
output:
84
result:
ok single line: '84'
Test #119:
score: 29
Accepted
time: 9ms
memory: 5508kb
input:
100 50 40 0 0 1 1 0 0 1 0 0 1 0 0 0 1 1 1 0 1 0 0 1 1 1 0 0 0 1 0 1 0 0 0 0 1 0 1 0 0 1 0 0 0 0 1 1 0 0 0 1 0 1 0 1 0 0 1 1 0 0 0 1 1 0 0 1 1 0 1 1 1 0 0 1 1 1 1 1 0 1 1 1 0 1 1 1 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1
output:
725
result:
ok single line: '725'
Test #120:
score: 29
Accepted
time: 8ms
memory: 5300kb
input:
100 50 60 1 0 0 0 0 1 1 0 1 1 1 0 1 0 0 1 1 0 0 0 1 1 0 1 1 1 1 1 0 0 1 1 0 1 0 0 1 1 1 1 1 1 1 0 0 1 0 0 0 0 1 0 1 1 1 1 1 1 1 1 0 0 1 0 0 1 0 1 0 1 1 1 0 1 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 1 1 0 1 0 1 0 0 1 0 1
output:
NO
result:
ok single line: 'NO'
Test #121:
score: 29
Accepted
time: 16ms
memory: 7112kb
input:
100 90 90 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1
output:
365
result:
ok single line: '365'
Test #122:
score: 29
Accepted
time: 14ms
memory: 6004kb
input:
100 60 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
0
result:
ok single line: '0'
Test #123:
score: 29
Accepted
time: 8ms
memory: 5620kb
input:
100 50 0 0 1 1 0 1 1 0 1 1 1 1 0 0 0 0 0 0 0 0 1 0 0 1 0 1 1 1 1 0 0 1 1 1 0 1 1 0 1 0 1 0 0 1 0 0 1 0 1 0 1 1 0 0 0 0 0 1 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 1 1 1 0 0 1 0 1 1 0 1 1 1 0 1 0 0 1 1 1 1 1 1
output:
0
result:
ok single line: '0'
Test #124:
score: 29
Accepted
time: 12ms
memory: 7196kb
input:
100 90 0 1 0 1 1 1 0 1 1 0 0 1 0 1 1 1 0 0 0 1 0 1 0 0 1 0 0 1 0 0 0 0 1 0 1 0 0 0 0 1 1 1 1 1 1 1 1 1 0 0 1 0 1 1 1 0 1 1 0 0 1 1 0 1 0 1 0 1 0 0 1 0 1 1 1 0 1 0 0 1 0 0 1 0 0 0 0 0 1 1 1 0 1 0 0 0 1 0 1 0 0
output:
0
result:
ok single line: '0'
Test #125:
score: 29
Accepted
time: 3ms
memory: 3660kb
input:
100 10 20 0 0 0 0 0 1 1 0 1 1 0 0 1 0 1 1 1 0 1 0 0 0 1 0 1 0 0 0 0 0 0 0 1 1 0 0 1 0 0 1 1 1 0 1 1 1 1 1 0 1 0 0 1 0 0 1 1 0 1 1 0 1 1 1 1 0 0 1 1 1 1 0 0 1 0 1 1 1 1 0 0 0 0 0 0 0 0 0 1 0 0 1 1 0 0 0 0 1 1 1
output:
NO
result:
ok single line: 'NO'
Test #126:
score: 29
Accepted
time: 9ms
memory: 5116kb
input:
100 50 100000000000 1 1 1 0 1 0 1 1 0 0 0 1 1 1 1 1 0 1 1 1 1 0 0 1 1 1 0 1 0 0 1 0 0 0 0 1 1 0 1 1 0 1 0 0 1 0 1 1 1 0 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 0 0 0 0 1 0 0 1 0 1 0 1 1 0 1 0 1 0 1 0 1 0 0 1 1 1 0
output:
NO
result:
ok single line: 'NO'
Test #127:
score: 29
Accepted
time: 12ms
memory: 5188kb
input:
100 50 8589934595 1 0 0 1 1 1 1 1 0 1 1 1 1 0 0 0 0 0 0 1 0 1 1 0 0 1 1 0 1 1 0 1 1 0 0 1 1 0 0 0 0 1 0 0 0 0 0 1 1 0 1 0 1 1 0 1 1 0 0 1 1 1 1 0 0 1 0 0 0 1 0 1 0 0 1 1 0 0 1 1 0 0 0 1 0 0 0 1 1 0 0 1 0 0 1 1 0 1 0 0
output:
NO
result:
ok single line: 'NO'
Test #128:
score: 29
Accepted
time: 0ms
memory: 3528kb
input:
3 1 7 4 5 6
output:
NO
result:
ok single line: 'NO'
Test #129:
score: 29
Accepted
time: 0ms
memory: 3612kb
input:
3 1 7 4 5 7
output:
2
result:
ok single line: '2'
Test #130:
score: 29
Accepted
time: 0ms
memory: 3580kb
input:
3 1 7 4 8 7
output:
1
result:
ok single line: '1'
Test #131:
score: 29
Accepted
time: 0ms
memory: 3608kb
input:
3 1 7 7 3 9
output:
0
result:
ok single line: '0'
Test #132:
score: 29
Accepted
time: 0ms
memory: 3612kb
input:
3 2 7 3 3 3
output:
NO
result:
ok single line: 'NO'
Test #133:
score: 29
Accepted
time: 0ms
memory: 3516kb
input:
3 2 7 2 3 4
output:
2
result:
ok single line: '2'
Test #134:
score: 29
Accepted
time: 0ms
memory: 3608kb
input:
3 2 7 3 2 4
output:
1
result:
ok single line: '1'
Test #135:
score: 29
Accepted
time: 0ms
memory: 3544kb
input:
3 2 7 4 5 6
output:
0
result:
ok single line: '0'
Test #136:
score: 29
Accepted
time: 0ms
memory: 3440kb
input:
3 3 7 1 3 2
output:
NO
result:
ok single line: 'NO'
Test #137:
score: 29
Accepted
time: 0ms
memory: 3608kb
input:
3 3 7 3 1 3
output:
0
result:
ok single line: '0'
Test #138:
score: 29
Accepted
time: 0ms
memory: 3580kb
input:
3 2 0 0 0 0
output:
0
result:
ok single line: '0'
Test #139:
score: 29
Accepted
time: 0ms
memory: 3548kb
input:
3 2 0 1 2 3
output:
0
result:
ok single line: '0'
Test #140:
score: 29
Accepted
time: 0ms
memory: 3656kb
input:
20 10 6566144533 323906753 73234 169258261 146483217 2526483 50563297 7173957 419870302 86885946 277634715 748939350 422834669 440114820 504900304 648304476 630339210 900877811 593594945 953548400 722690548
output:
100
result:
ok single line: '100'
Test #141:
score: 29
Accepted
time: 0ms
memory: 3812kb
input:
20 10 6164244072 155183169 228236990 208003086 343519393 203430078 129307145 158643368 33100189 235687056 222657550 413967161 896436020 887689465 550380926 691043319 946504501 444961305 475841383 388568669 468851323
output:
100
result:
ok single line: '100'
Test #142:
score: 29
Accepted
time: 0ms
memory: 3872kb
input:
20 18 9610913809 58382570 1322710 654840381 202842775 300914313 462981306 141101410 670033653 737028856 888310178 420221248 393987230 214258398 897791395 261977352 762131762 938005468 558347054 363867624 742273406
output:
36
result:
ok single line: '36'
Test #143:
score: 29
Accepted
time: 0ms
memory: 3532kb
input:
20 8 8000000000 1000000000 999999999 1000000000 1000000000 999999999 999999999 999999999 1000000000 1000000000 999999999 1000000000 1000000000 999999999 999999999 999999999 1000000000 999999999 1000000000 999999999 1000000000
output:
28
result:
ok single line: '28'
Test #144:
score: 29
Accepted
time: 0ms
memory: 3568kb
input:
20 12 12000000000 1000000000 1000000000 999999999 999999999 1000000000 999999999 1000000000 999999999 999999999 1000000000 1000000000 999999999 1000000000 999999999 999999999 1000000000 1000000000 1000000000 1000000000 1000000000
output:
61
result:
ok single line: '61'
Test #145:
score: 29
Accepted
time: 0ms
memory: 3812kb
input:
20 12 12000000000 999999999 999999999 999999999 999999999 1000000000 999999999 1000000000 999999999 1000000000 1000000000 1000000000 1000000000 1000000000 999999999 1000000000 999999999 1000000000 1000000000 1000000000 999999999
output:
NO
result:
ok single line: 'NO'
Test #146:
score: 29
Accepted
time: 0ms
memory: 3624kb
input:
20 10 3333333333 263624178 602898190 420963433 437884997 29710349 491478505 762760712 223384385 55154427 247361461 311280665 796832434 325014303 418646560 443155385 309305851 287458918 290458843 73509473 381919309
output:
0
result:
ok single line: '0'
Test #147:
score: 29
Accepted
time: 0ms
memory: 3596kb
input:
20 10 6800000000 6727977 168476741 640453099 745909210 465912066 597929442 309004415 752756925 512558999 407756549 699491803 550336604 928590530 509682749 930053726 972170609 830489125 317341090 602598601 786818691
output:
28
result:
ok single line: '28'
Test #148:
score: 29
Accepted
time: 0ms
memory: 3540kb
input:
20 10 8400000000 490759429 577739494 777938828 26684416 983875443 660699290 311443997 945777950 948498829 437718566 114473495 420625153 506020763 85582893 767427548 976050679 783422475 168447458 633031695 182488951
output:
NO
result:
ok single line: 'NO'
Test #149:
score: 29
Accepted
time: 0ms
memory: 3612kb
input:
20 10 3000000000 132894078 60976811 122272635 118825862 344797520 499759987 416983334 464948474 332856593 716815545 587427340 521430452 580842697 777336152 740614865 773332159 910211548 760580366 872763270 862088305
output:
0
result:
ok single line: '0'
Test #150:
score: 29
Accepted
time: 0ms
memory: 3504kb
input:
20 10 4000000000 201987269 198126981 158756144 188296059 182086700 262863090 543395895 372218384 432780571 419887028 510659429 556696166 384624599 668282669 672913794 605220743 692335425 477735221 622621736 842880145
output:
21
result:
ok single line: '21'
Test #151:
score: 29
Accepted
time: 0ms
memory: 3808kb
input:
20 10 5000000000 144425144 110530990 359934042 0 400143548 443138967 331050017 638875702 268160577 558102915 551357335 724461476 658896595 662039701 706213909 756666187 789234319 631704115 935768714 876353223
output:
26
result:
ok single line: '26'
Test #152:
score: 29
Accepted
time: 0ms
memory: 3532kb
input:
20 10 6000000000 240858929 20956451 271016582 198575969 414187671 287687480 267328642 166255826 612041111 742856091 544779310 462660138 721565200 712987358 613477373 861977305 772887187 754803381 751790051 806510817
output:
51
result:
ok single line: '51'
Test #153:
score: 29
Accepted
time: 0ms
memory: 3624kb
input:
20 10 7000000000 72400301 253293083 88322729 203869372 305687730 15909565 444043421 507401475 548666163 495533730 479026621 615617352 677540315 756907917 753695398 609838578 887405794 651243868 791919978 907717036
output:
88
result:
ok single line: '88'
Test #154:
score: 29
Accepted
time: 0ms
memory: 3868kb
input:
20 10 8000000000 239757482 257154616 26372785 260661934 255928849 390775920 305428517 432319097 334310334 398076038 518978541 494543443 527856458 736609886 858915291 753585415 832823371 804815588 905429868 846897833
output:
NO
result:
ok single line: 'NO'
Test #155:
score: 29
Accepted
time: 0ms
memory: 3672kb
input:
20 18 9400000000 233234959 239533200 196553166 246868328 201443657 349435478 348192133 296370133 507063613 437055050 375561412 669201134 621129480 598775583 518467201 737587081 757134181 924422699 821116542 1000000000
output:
20
result:
ok single line: '20'
Test #156:
score: 29
Accepted
time: 0ms
memory: 3552kb
input:
20 18 18000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 999999999 1000000000 1000000000 1000000000 999999999 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000
output:
21
result:
ok single line: '21'
Test #157:
score: 29
Accepted
time: 0ms
memory: 3640kb
input:
5 5 123123123 1000000000 1000000000 0 0 0
output:
0
result:
ok single line: '0'
Test #158:
score: 29
Accepted
time: 12ms
memory: 5560kb
input:
100 50 3621 24 39 10 12 22 36 39 0 2 30 33 24 14 36 3 30 20 10 34 28 29 41 1 20 19 26 29 37 4 31 27 36 8 3 25 24 11 36 4 14 25 31 25 35 34 16 36 23 25 30 58 63 85 90 88 72 54 55 47 83 57 51 52 93 45 48 76 68 78 100 71 87 60 72 90 71 61 97 66 63 78 42 89 93 80 86 93 73 88 52 44 76 87 63 100 77 87 81 ...
output:
2500
result:
ok single line: '2500'
Test #159:
score: 29
Accepted
time: 12ms
memory: 5832kb
input:
100 50 3676 23 8 17 28 35 0 22 36 7 35 36 4 34 40 19 27 2 7 11 16 28 7 26 23 26 12 15 41 10 21 29 10 6 32 14 14 35 31 43 22 42 0 44 30 3 50 26 16 24 35 84 99 86 82 52 84 80 57 64 54 64 98 87 56 77 77 98 62 91 64 54 74 63 94 68 65 59 65 92 99 55 61 56 74 52 57 73 88 92 95 69 53 67 90 85 60 57 86 60 97
output:
2500
result:
ok single line: '2500'
Test #160:
score: 29
Accepted
time: 18ms
memory: 7480kb
input:
100 98 4937 2 0 36 15 56 28 90 5 67 80 48 9 33 33 14 34 67 75 87 28 82 83 96 24 70 37 43 16 96 95 91 24 69 22 57 28 43 38 44 73 24 93 16 100 71 32 39 23 56 19 70 30 70 78 57 13 55 82 67 86 6 37 60 73 41 56 23 24 54 91 85 15 68 90 26 67 27 45 37 13 27 33 49 75 85 31 26 48 12 74 98 11 3 15 76 23 97 54...
output:
196
result:
ok single line: '196'
Test #161:
score: 29
Accepted
time: 11ms
memory: 5144kb
input:
100 40 4000 99 100 99 99 99 99 100 100 100 100 99 99 99 99 100 99 99 99 99 100 100 100 99 100 99 100 100 100 100 99 99 100 99 99 99 99 100 100 100 99 99 99 99 99 99 100 99 100 99 100 100 100 99 99 99 100 100 100 100 99 100 99 99 99 99 100 100 99 100 100 100 100 99 99 100 100 99 100 99 100 100 100 10...
output:
999
result:
ok single line: '999'
Test #162:
score: 29
Accepted
time: 14ms
memory: 6016kb
input:
100 60 6000 100 100 100 100 100 99 100 100 99 99 100 100 99 100 100 100 99 100 99 99 99 100 100 100 100 100 100 100 100 100 100 99 100 100 99 100 100 100 99 99 100 100 99 100 100 99 100 100 99 99 100 99 99 100 99 100 99 100 100 99 99 99 100 100 99 100 100 100 100 100 100 100 99 100 100 99 100 99 100...
output:
887
result:
ok single line: '887'
Test #163:
score: 29
Accepted
time: 14ms
memory: 5480kb
input:
100 60 6000 99 99 99 99 100 99 99 100 100 99 100 99 100 99 100 100 99 99 99 100 99 100 99 100 99 100 99 99 99 99 99 99 100 99 99 99 99 99 100 99 100 100 99 100 100 100 100 99 100 99 100 100 100 99 99 100 99 100 100 100 99 100 100 100 100 100 100 100 100 100 100 100 99 100 99 99 100 99 100 100 100 99...
output:
NO
result:
ok single line: 'NO'
Test #164:
score: 29
Accepted
time: 12ms
memory: 5836kb
input:
100 50 1666 12 30 25 26 66 14 52 26 47 7 77 12 68 100 89 38 43 74 48 99 88 28 54 31 21 39 23 77 3 18 78 35 1 4 93 43 90 98 10 59 93 93 81 3 37 22 68 66 77 32 30 19 98 99 66 62 19 12 49 95 75 96 15 42 27 42 95 100 10 0 2 82 3 74 58 54 66 65 70 35 68 17 3 76 14 22 77 34 7 94 90 1 23 8 94 9 22 76 16 58
output:
0
result:
ok single line: '0'
Test #165:
score: 29
Accepted
time: 12ms
memory: 5620kb
input:
100 50 3400 93 69 6 55 88 45 99 26 89 90 35 21 94 1 35 73 95 90 78 22 50 2 79 28 4 81 56 22 8 40 25 37 15 12 10 23 38 71 80 2 58 30 63 97 41 38 42 58 89 23 72 74 39 12 92 45 19 72 71 3 96 71 28 38 84 2 94 87 71 16 1 47 22 45 71 35 92 8 41 86 51 27 14 14 89 93 37 73 12 81 49 36 25 33 75 94 79 37 25 25
output:
477
result:
ok single line: '477'
Test #166:
score: 29
Accepted
time: 9ms
memory: 5300kb
input:
100 50 4200 12 24 3 74 72 71 27 71 26 66 1 35 47 21 84 73 2 99 80 96 19 2 56 83 16 61 68 62 24 52 94 37 50 73 80 13 79 14 74 15 99 88 57 42 79 41 43 61 50 2 31 19 47 66 56 72 63 52 37 55 42 80 79 82 99 25 10 4 70 87 54 54 85 21 80 79 90 76 58 88 43 72 40 78 82 27 60 18 97 21 10 80 17 3 48 1 48 31 10...
output:
NO
result:
ok single line: 'NO'
Test #167:
score: 29
Accepted
time: 8ms
memory: 5592kb
input:
100 50 1500 8 0 21 17 5 11 8 0 25 19 17 35 13 15 24 34 20 25 36 12 24 12 19 20 24 24 50 21 29 26 36 10 28 32 24 33 37 39 37 29 43 27 38 45 62 40 42 40 42 55 65 53 75 37 56 45 43 60 48 45 79 53 55 41 70 74 38 73 73 68 58 87 74 68 57 64 61 66 62 86 55 75 88 69 87 67 80 97 74 80 84 68 76 76 99 91 95 69...
output:
54
result:
ok single line: '54'
Test #168:
score: 29
Accepted
time: 12ms
memory: 5544kb
input:
100 50 2000 22 3 13 20 19 0 9 13 7 5 19 17 18 0 43 21 29 27 23 15 34 27 32 40 34 22 28 26 31 49 26 35 38 28 21 35 20 46 74 46 49 37 34 48 37 43 56 53 33 44 56 60 52 40 49 55 50 70 65 56 60 71 54 74 59 55 53 58 71 62 57 85 78 66 59 72 54 73 64 71 88 79 69 75 80 72 90 72 82 75 89 82 85 90 98 88 85 91 ...
output:
363
result:
ok single line: '363'
Test #169:
score: 29
Accepted
time: 12ms
memory: 5532kb
input:
100 50 2500 20 15 4 13 21 0 10 17 17 8 28 0 21 28 18 11 7 30 0 18 21 8 33 32 22 30 24 24 36 22 34 39 42 44 44 39 45 47 26 42 46 49 36 55 48 21 42 59 53 52 41 52 47 41 53 74 55 43 52 65 57 58 82 52 55 60 57 77 63 86 70 62 65 53 81 88 69 95 77 86 84 83 81 72 66 75 97 82 87 76 91 84 87 75 98 86 78 94 9...
output:
840
result:
ok single line: '840'
Test #170:
score: 29
Accepted
time: 13ms
memory: 5808kb
input:
100 50 3000 17 0 3 17 22 18 12 0 0 7 49 11 29 11 34 24 28 19 23 20 24 39 16 37 31 18 26 28 32 32 33 40 30 40 43 46 38 34 40 40 36 50 49 40 43 30 39 61 44 43 46 39 56 61 43 68 69 47 62 67 61 54 52 52 77 63 61 67 48 83 73 67 63 62 100 82 77 82 71 82 73 74 83 73 91 69 70 62 80 88 78 79 100 90 100 94 90...
output:
1382
result:
ok single line: '1382'
Test #171:
score: 29
Accepted
time: 12ms
memory: 5652kb
input:
100 50 3500 15 5 24 11 15 19 31 10 6 13 17 26 13 11 13 12 38 29 34 25 30 34 13 46 27 30 15 31 36 25 39 19 24 37 23 45 45 31 38 56 42 40 46 38 38 47 50 57 37 51 49 58 51 34 60 51 55 37 72 61 49 71 62 66 69 34 47 76 76 54 65 69 55 88 68 71 55 80 79 91 74 68 81 83 85 73 73 84 81 77 91 82 81 87 82 95 77...
output:
2243
result:
ok single line: '2243'
Test #172:
score: 29
Accepted
time: 13ms
memory: 5148kb
input:
100 50 4000 17 10 26 6 1 20 7 0 10 11 11 29 21 29 32 33 7 35 30 42 20 21 14 28 23 36 45 56 32 21 44 34 28 29 45 47 34 33 35 43 51 41 49 37 34 43 41 61 54 56 40 56 57 70 32 43 61 55 72 56 78 61 61 63 65 63 73 63 68 83 81 82 57 62 67 59 69 66 68 84 86 69 72 63 66 80 77 87 88 68 84 78 74 100 93 75 89 9...
output:
NO
result:
ok single line: 'NO'
Test #173:
score: 29
Accepted
time: 13ms
memory: 7080kb
input:
100 90 4700 15 24 0 4 5 7 17 26 18 33 25 39 12 32 14 10 9 14 8 14 31 19 28 14 33 21 27 39 21 33 40 45 46 49 26 49 20 44 41 37 47 38 43 56 45 46 44 56 54 37 73 48 49 51 71 69 47 70 64 66 65 70 52 78 51 76 44 67 53 75 67 71 74 58 64 84 77 69 73 74 64 74 69 82 82 68 89 81 79 89 83 75 72 64 88 86 81 83 ...
output:
532
result:
ok single line: '532'
Test #174:
score: 29
Accepted
time: 17ms
memory: 7080kb
input:
100 90 9000 100 100 100 100 100 100 100 100 99 100 100 100 100 100 100 100 100 100 99 100 99 100 100 100 100 99 100 99 99 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 99 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100 100...
output:
498
result:
ok single line: '498'
Test #175:
score: 29
Accepted
time: 13ms
memory: 5776kb
input:
100 50 37905234160 286663842 276604569 175995957 255151321 513059416 363024553 249398416 170579711 453554916 125480404 147452032 266638190 172975114 368448224 232405182 198205948 395820442 175074192 135223907 244915415 467987653 175280770 172138106 415016795 358553168 510087829 165266104 277301574 1...
output:
2500
result:
ok single line: '2500'
Test #176:
score: 29
Accepted
time: 8ms
memory: 5560kb
input:
100 50 36341209581 343719091 106798510 40846699 294302064 331299079 26892940 138054240 298740925 22510548 218728150 417132199 60983561 369869124 156754365 35248505 266478030 122421844 143800233 343955688 127121768 398000101 389144632 289753976 69877709 54105585 375534615 336842284 227755128 38961257...
output:
2500
result:
ok single line: '2500'
Test #177:
score: 29
Accepted
time: 13ms
memory: 7396kb
input:
100 98 48927103957 21445779 14744248 254097704 175500795 46439337 748834995 585216225 143382434 952663850 254400329 88275705 29611798 661204324 301929143 816127788 290218915 739770230 863580541 415939898 178802180 335128700 678057940 272326694 72153924 234962180 563770702 53847785 53125451 308938828...
output:
196
result:
ok single line: '196'
Test #178:
score: 29
Accepted
time: 7ms
memory: 5224kb
input:
100 40 40000000000 1000000000 1000000000 999999999 1000000000 1000000000 1000000000 1000000000 999999999 1000000000 1000000000 1000000000 999999999 999999999 1000000000 999999999 1000000000 999999999 999999999 1000000000 1000000000 999999999 999999999 1000000000 999999999 999999999 999999999 1000000...
output:
757
result:
ok single line: '757'
Test #179:
score: 29
Accepted
time: 14ms
memory: 6248kb
input:
100 60 60000000000 1000000000 1000000000 999999999 999999999 1000000000 999999999 1000000000 1000000000 1000000000 1000000000 999999999 1000000000 999999999 999999999 999999999 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 999999999 999999999 1000000000 1000000000 9999...
output:
1104
result:
ok single line: '1104'
Test #180:
score: 29
Accepted
time: 14ms
memory: 5632kb
input:
100 60 60000000000 1000000000 1000000000 999999999 999999999 999999999 1000000000 1000000000 999999999 999999999 1000000000 999999999 1000000000 1000000000 999999999 1000000000 999999999 1000000000 1000000000 999999999 1000000000 999999999 1000000000 999999999 999999999 1000000000 999999999 99999999...
output:
NO
result:
ok single line: 'NO'
Test #181:
score: 29
Accepted
time: 12ms
memory: 5560kb
input:
100 50 16666666666 788815271 242459922 25590866 794166206 504467558 379523857 622186892 834126871 600759972 804060476 771801230 909248863 102471065 290748491 380872410 336275265 948732652 361553576 624347920 521893614 398189997 117750710 748567989 419713805 396786602 710304272 467288400 18532330 686...
output:
0
result:
ok single line: '0'
Test #182:
score: 29
Accepted
time: 12ms
memory: 5536kb
input:
100 50 34000000000 624921058 375573325 87795425 909518675 368281303 378857340 405426320 530896857 693998922 859120120 617178105 203516518 575773007 845339980 9485651 121839737 591686076 59517571 302422798 555529796 242748604 576950546 386107465 757505122 360138481 959270991 975404524 452216828 62923...
output:
385
result:
ok single line: '385'
Test #183:
score: 29
Accepted
time: 8ms
memory: 5224kb
input:
100 50 42000000000 373336684 210297147 436595741 772700354 75762985 781054399 702437372 454588140 968120827 640988296 838993173 739555219 310174224 516206674 961030627 87873552 187439442 828569133 303986214 910972567 57233091 223540753 124093100 532345611 513474612 486934085 67489139 743870474 74848...
output:
NO
result:
ok single line: 'NO'
Test #184:
score: 29
Accepted
time: 8ms
memory: 5624kb
input:
100 50 15000000000 226400671 53751067 80361479 0 278532944 100138295 103777193 196830722 0 129790518 149911956 361940397 87229840 101180440 409901543 329555352 250803404 224996587 232139074 204796236 267732856 282736900 205453160 352627789 356912131 458376849 477027927 336967077 319593145 401519626 ...
output:
0
result:
ok single line: '0'
Test #185:
score: 29
Accepted
time: 8ms
memory: 5544kb
input:
100 50 20000000000 84536998 0 44860743 79115814 121402953 50524819 103378495 235893892 128337795 178778078 221849191 234865367 260506120 250038508 252056874 306521373 39623490 226776018 172098857 263764404 118308278 309471463 311293792 191004121 388044625 169048234 347176164 174755078 301461479 2454...
output:
406
result:
ok single line: '406'
Test #186:
score: 29
Accepted
time: 12ms
memory: 5652kb
input:
100 50 25000000000 116736551 79497289 165642697 102759749 51616417 224508397 60988004 84844566 193432427 144058545 252812319 285074458 260903412 326674232 366805598 227663261 187189902 13512431 319721432 83065826 516366041 134212949 429136143 287082474 439667552 211106186 391669225 241877553 2975646...
output:
725
result:
ok single line: '725'
Test #187:
score: 29
Accepted
time: 12ms
memory: 5620kb
input:
100 50 30000000000 142322734 204136698 128113242 79967637 0 182010254 344566076 150444456 68170012 555931134 341248006 233846161 288265739 316277264 278064847 308278761 305324423 288157641 316538361 243641644 293356625 222467084 351450719 296284879 431013485 264645618 341282707 286746006 361275741 2...
output:
1372
result:
ok single line: '1372'
Test #188:
score: 29
Accepted
time: 12ms
memory: 5784kb
input:
100 50 35000000000 9651257 0 149830560 177777488 181753683 179667232 0 182783353 135337818 283651105 91005209 234304308 191134991 425376585 197544032 0 113065989 312308943 295145525 50899180 178280092 112454468 295319898 63006525 407795471 280526250 218216586 220780056 280412850 487392864 454195199 ...
output:
2300
result:
ok single line: '2300'
Test #189:
score: 29
Accepted
time: 12ms
memory: 5104kb
input:
100 50 40000000000 0 99981717 125221518 107159534 90193486 0 42075893 322581128 233449764 151747631 48141385 186446079 201909508 184060881 339383643 250186826 301597595 154935369 184167669 125115348 151656669 274894801 240478366 172658652 112755177 308313438 348261588 140473505 287753926 238110910 3...
output:
NO
result:
ok single line: 'NO'
Test #190:
score: 29
Accepted
time: 16ms
memory: 7108kb
input:
100 90 47000000000 0 0 0 108714489 369346514 1626945 118843401 237377928 210892311 39967517 203202692 161449414 205459628 299262144 145370708 212775966 391257960 79771666 190028228 241976650 352833662 174555964 222770613 228915467 266809248 199206281 164706894 247833891 335455131 385081958 206722710...
output:
539
result:
ok single line: '539'
Test #191:
score: 29
Accepted
time: 16ms
memory: 7152kb
input:
100 90 90000000000 1000000000 1000000000 1000000000 1000000000 1000000000 999999999 1000000000 1000000000 999999999 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 10000000...
output:
412
result:
ok single line: '412'
Test #192:
score: 29
Accepted
time: 0ms
memory: 3520kb
input:
6 2 27 10 4 20 6 3 3
output:
1
result:
ok single line: '1'
Test #193:
score: 29
Accepted
time: 0ms
memory: 3608kb
input:
6 5 5000000000 1000000000 1000000000 0 1000000000 1000000000 1000000000
output:
3
result:
ok single line: '3'
Test #194:
score: 29
Accepted
time: 0ms
memory: 3844kb
input:
3 2 100 20 30 60
output:
NO
result:
ok single line: 'NO'
Test #195:
score: 29
Accepted
time: 0ms
memory: 3536kb
input:
1 1 100 100
output:
0
result:
ok single line: '0'
Extra Test:
score: 0
Extra Test Passed