QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#293495#7122. Overtakinghyforces100 ✓1454ms56216kbC++202.7kb2023-12-29 11:30:492024-04-28 08:22:54

詳細信息

Subtask #1:

score: 9
Accepted

Test #1:

score: 9
Accepted
time: 2ms
memory: 8604kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2500 1 78 100 1000
100000
80
0 38 51 89 92 105 117 119 122 126 142 179 259 355 385 410 419 443 483 496 551 671 691 698 709 762 778 818 860 888 897 909 930 938 946 951 955 995 1045 1091 1164 1187 1215 1243 1264 1301 1363 1409 1416 1448 1504 1518 1535 1555 1562 1597 16...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
299664
298224
299166
298008
295102
298070
297182
298650
298312
296396
296524
298070
295838
296910
296892
297374
298684
295184
295710
299062
296382
298684
298110
298008
299530
298766
295966
299062
296794
298998
299738
296418
298588
296876
295102
299860
295710
29577...

result:

ok 

Test #2:

score: 9
Accepted
time: 4ms
memory: 21036kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
80000001 1 151251000 400 1000
10000
151251252
0 563193 647572 715146 1130358 1138744 1557704 2110181 2300143 2420378 2557533 2614949 2657752 2838017 2861875 3146425 3202178 3240281 3248583 3280296 3310987 3401711 3683587 3943976 4135364 4214616 4277932 4503844 476465...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
12100095744014512
12100080944160100
12100085508223828
12100095197505388
12100090627084960
12100097311519276
12100080683026612
12100093846636708
12100099968098740
12100096796223124
12100096142019784
12100097662974856
12100083572845936
12100099936140100
121000877792...

result:

ok 

Test #3:

score: 9
Accepted
time: 4ms
memory: 26592kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
700000000 1 199 800 1000
2000
200
0 2547880 2899696 3746196 5005561 5262711 7391315 7766094 8058134 12302379 14113798 14139018 16263685 19246991 20293858 21308475 21531629 21609437 22819772 23818245 23866117 24082599 24830023 25092620 25219376 27345462 27398799 28906...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
139981678448
139714673517
139493728857
139777641660
139908912147
139434676500
139585452046
139704974839
139718370512
139701821327
139448528458
139463864882
139927337590
139754511858
139416197864
139844650005
139808181948
139577750390
139643626646
139688190761
1396...

result:

ok 

Test #4:

score: 9
Accepted
time: 0ms
memory: 27596kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000000 1 99 1000 1000
1000000000000
100
0 1817308 2789727 3514387 5238876 5972281 7743105 8541339 9248161 10089380 11281389 11329343 14077050 14155477 16510318 19268709 19528706 19612683 19893513 20400622 21278533 21582205 24880066 27530395 27569486 28339765 2922...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1099248330619
1099325193168
1099666752580
1099563034876
1099525957106
1099785654428
1099996241055
1099847005338
1099823366993
1099082743936
1099501468836
1099332698857
1099168227471
1099262165670
1099409777071
1099821586703
1099761464774
1099878195061
109999213744...

result:

ok 

Test #5:

score: 9
Accepted
time: 2ms
memory: 27596kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000000 1 880000000 1000 1000
100000000000000000
880001000
0 709332 1017351 1905741 3045292 3464378 3632596 5704941 6735246 9747846 10704021 12434640 13264129 14081255 14176931 15634238 17365369 18691988 19399867 20069605 21121920 23160840 23345820 24551706 255281...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
980000473593602000
980000328241893000
980000496751131000
980000100732727000
980000460850951000
980000615531582000
980000605439144000
980000435818946000
980000696831126000
980000166079150000
980000940725540000
980000805086273000
980000698057886000
98000016833636000...

result:

ok 

Test #6:

score: 9
Accepted
time: 0ms
memory: 28612kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1 498 1000 1000
100000000000000000
500
0 160783 205816 346327 347823 367191 395170 441295 639474 718881 831118 875863 1298479 1319125 1431282 1514976 1596686 1644592 1644648 1671765 1680769 1760215 1869745 1989596 2020399 2106354 2289587 2488522 2594930 272...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
100000049926232916
100000049864514052
100000049973025928
100000049995005458
100000049930515196
100000049843074864
100000049920623428
100000049897187068
100000049802862564
100000049946008956
100000049946867894
100000049917050904
100000049822989734
10000004993122233...

result:

ok 

Test #7:

score: 9
Accepted
time: 1ms
memory: 3908kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1 401 1000 1000
100000000000000000
400
0 31311 143468 183347 233725 256130 444842 481905 486233 527809 549435 664450 1549723 1573249 1619077 1673590 1911655 1913292 2059722 2158189 2259116 2349409 2426923 2437811 2474156 2510525 2528753 2614955 2695324 2871...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
100000040105826882
100000040124582713
100000040181245022
100000040169641106
100000040135428053
100000040137403238
100000040172575752
100000040194573555
100000040163594943
100000040110810308
100000040187649357
100000040116517222
100000040114627594
10000004013557963...

result:

ok 

Test #8:

score: 9
Accepted
time: 1ms
memory: 7948kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10 1 5 5 10
0
6
0 2 8 9 10
9
2
4
5
0
1
2
3
10
20

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
59
52
58
58
50
52
52
58
60
70

result:

ok 

Test #9:

score: 9
Accepted
time: 0ms
memory: 8284kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000000 1 880000000 100 100
100000000000000000
880001000
0 18125472 18662947 20132713 38844162 50912725 59000193 70694095 79014902 84781895 107240650 124792182 125767204 150665436 158106715 162875579 169664865 184892442 192426843 210142654 221584689 224390935 2398...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
980000939022239000
980000210142654000
980000989457694000
980000307752813000
970286252078123694
980000000000000000
980000902460888000
980000434973267000
980000906339786000
980000526408935000
980000282731536000
980000434973267000
980000210142654000
98000016966486500...

result:

ok 

Test #10:

score: 9
Accepted
time: 0ms
memory: 12656kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1 498 100 100
100000000000000000
500
0 829700 1359408 1753928 1877428 2734456 2977184 3054027 3673453 4432770 5771214 5906467 8822394 10489610 11221287 11534731 16500729 19052276 19320520 20664138 20737902 22046077 23121119 29574967 29854061 30109803 304197...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
100000049863849700
100000049962684802
100000049805468912
100000049838104552
100000049869485964
100000049879617250
100000049817644788
100000049913581290
100000049862347240
100000049869319444
100000049995389460
100000049802718816
100000049928978048
10000004992176166...

result:

ok 

Test #11:

score: 9
Accepted
time: 1ms
memory: 3752kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1 401 100 100
100000000000000000
400
0 1310416 2393682 2579012 3615394 6750570 6794866 6934895 7799665 8347376 8621879 9284983 10987581 12631682 14785700 15715498 16575943 17379309 18460496 18774602 19006189 20255533 22914625 23446266 25870132 26382507 2818...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
100000040195912004
100000040167926330
100000040172845150
100000040194544782
100000040108588211
100000040142271715
100000040141179703
100000040108392021
100000040123135941
100000040177546716
100000040116164403
100000040118375302
100000040115008407
10000004017282049...

result:

ok 

Subtask #2:

score: 10
Accepted

Test #12:

score: 10
Accepted
time: 0ms
memory: 8228kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2000000 100 100 2 1000
566035866 424023571 564031634 266012245 266012901 566037245 106005324 106003684 266012594 424028440 424019007 106005224 564034079 424024371 424024546 566039191 424016814 424029581 82000890 754044052 566036512 424018510 424017279 424019925 42401...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
768035150
768029581
1144044184
308008207
768029581
768029581
956039191
768029581
956041170
768029581
768029581
308008207
956039191
308008207
768029581
768029891
1144044184
418008550
768029581
468009953
308008207
1144044184
768035150
768029581
468010817
768029581
6...

result:

ok 

Test #13:

score: 10
Accepted
time: 1ms
memory: 7952kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 400 1011 2 1000
173387969125 200337983261 77920310897 77652037350 182097978669 118267907350 174157972712 57062023028 118267909308 107247901578 174157973485 146027951049 53742020545 118267912197 174167974422 207927989121 137207921414 143227933063 77992040344 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
128387906425
192867977136
218447987834
162297954325
192867978986
34992000977
147437922857
192867979350
67182020640
56912011273
63862013824
162297954325
43302006404
92682052132
120767905711
218447987834
98882054684
138667917161
63862014242
117367898279
210667984418...

result:

ok 

Test #14:

score: 10
Accepted
time: 2ms
memory: 8024kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000 800 1522451 2 1000
102691961165 356949771920 280550316262 154390571762 439415828789 473733275923 465056851706 434971147676 473185083883 407141567243 446269133331 245826204010 132720147100 266857422544 300276587668 200566213815 304647607947 8994460481 3661139508...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
480548847785
422389308676
261050720686
480548847785
24218980889
488958822294
290598660610
61394536039
454767827473
117916481772
160323101016
454767828952
109098515326
222192213960
467092876761
319997647668
369154287532
146931915291
501350951422
319997648312
242189...

result:

ok 

Test #15:

score: 10
Accepted
time: 2ms
memory: 7980kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
500000 1000 10000 2 1000
148512009450 164605927216 127484617319 27096740437 161301908126 227401559568 220855479544 152976736303 161069395645 159703894172 122292102200 189557102648 122405102528 39895753566 164605425801 106641054484 84900003806 152618881097 73504974935...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
237134063601
77319966760
172553429697
60674183017
13155506385
85565990030
188380679354
132653620072
213967471779
69226440539
137641624766
166302397011
221523969131
80847981443
46376261447
37662245837
106741029379
130318611384
221523968061
93106503930
230318554599
...

result:

ok 

Test #16:

score: 10
Accepted
time: 2ms
memory: 7976kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
500000 1000 10000 2 1000
36612285378 23369050451 152360966961 15872520226 182265836399 188728204731 213864007043 57066096669 80835239061 207526883647 43857790862 65146624890 89690753835 154413657390 20424038673 49803808788 126917115886 52711828720 118899204834 158725...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
66580596995
198079362901
188002837585
194288360880
167111986766
73714107129
222229390881
108513769364
159439969371
25424526704
108513769364
25424526704
186703323340
108513769364
10576002438
140488624579
62066832985
36920571209
157371466325
100548265663
15330145069...

result:

ok 

Test #17:

score: 10
Accepted
time: 0ms
memory: 8244kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
500000 1000 10000 2 1000
4337004497 176521204259 51880125384 34694128785 180975708661 218870562416 97250810605 114586115166 24846112541 64565181841 125706138427 91643555516 73078310445 109339605796 117687618529 131699541732 8692016529 131699546538 62862679197 2229305...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
57488656585
119672114103
159363389223
80550700997
193898735338
201967251391
209771544023
186206211435
61144668391
178885696551
195291238682
205565526206
108392081703
148442568746
201967251391
122724619987
186206206389
39694619414
108392081703
61144668391
396946227...

result:

ok 

Test #18:

score: 10
Accepted
time: 0ms
memory: 8040kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1 1000 1 2 1000
655 476 606 503 746 669 142 668 383 118 398 946 53 282 396 67 739 265 86 976 405 472 467 350 740 326 426 516 763 329 894 645 782 34 390 44 614 387 539 527 88 437 978 873 155 46 190 725 613 957 111 342 605 483 295 333 766 981 177 716 371 424 572 338 70...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
759
863
796
178
489
864
882
160
829
938
525
707
820
894
910
783
458
24
945
913
265
774
764
775
890
885
844
807
803
872
869
992
784
922
792
867
888
764
682
844
962
209
363
325
726
197
793
914
821
984
772
302
689
219
840
844
774
898
776
526
945
835
976
756
812
923
9...

result:

ok 

Test #19:

score: 10
Accepted
time: 2ms
memory: 8044kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100 1000 99 2 1000
64001 97600 61200 79400 29101 55800 93800 44301 22300 74300 22201 41601 76700 29901 20101 12000 71600 27101 82100 97101 27300 41000 95901 81701 78200 55100 69800 63901 20901 72301 19700 4600 39201 1401 83900 96601 82201 59401 86101 47101 36000 5260...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
99300
91701
51901
31500
15200
102101
97700
98400
35101
66300
65200
36101
63200
97600
94900
26301
47900
30800
29700
59701
108501
104601
85901
23401
85701
24401
84801
93900
102900
100201
86100
99000
52900
91701
56601
66101
92100
19001
92800
85500
95200
92501
104300
...

result:

ok 

Test #20:

score: 10
Accepted
time: 0ms
memory: 7980kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100023 1000 99969 2 1000
71100012 35700009 8700018 61050026 83400030 54450025 54750038 120450017 64800013 10500023 76800032 16050036 78600027 63600045 66150037 145800039 60150037 121800000 106050014 87750006 99900036 17250014 133500018 147300004 1200020 89250004 1995...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
10146301067
10132551175
10106701119
10124101130
10152451038
10013351130
10151051088
10109651134
10135451092
10065251142
10146301067
10030801116
10140450968
10147551038
10118151062
10133651147
10017001154
10124101130
10072951004
10131001083
10151400931
10048301151
...

result:

ok 

Test #21:

score: 10
Accepted
time: 1ms
memory: 3788kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000 1000 100 2 1000
518750000 156250000 616250000 28750000 330000000 76250000 546250000 478750000 177500000 190000000 426250000 356250000 471250000 58750000 387500000 408750000 558750000 428750000 597500000 112500000 555000000 215000000 617500000 168750000 46000000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
287250000
546163278
472230595
332250000
589965320
564195418
90709123
469750000
593482524
15456025
469750000
364750000
147250000
602250000
256721924
190332096
206670991
139750000
626233926
218500000
373941180
478939882
99939212
387250000
155407640
467136517
8165238...

result:

ok 

Test #22:

score: 10
Accepted
time: 1ms
memory: 3840kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000 1000 100 2 1000
15750000 13500000 181500000 367500000 188250000 183000000 294750000 45750000 233250000 1500000 48750000 186750000 308250000 362250000 324000000 249000000 50250000 193500000 207000000 215250000 68250000 111000000 189750000 60000000 204750000 3112...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
4537693
25000000
150676482
172359551
298208750
295442591
370000000
326661512
121535016
58028889
275245071
240466612
286282573
49750000
264250000
271637019
304490046
245500000
34750000
292750000
93250000
325687081
341500000
166750000
374500000
115816035
189986704
1...

result:

ok 

Test #23:

score: 10
Accepted
time: 0ms
memory: 7912kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
500000 100 10000 2 100
16997989753 22378679076 22455180036 21827670855 22450246771 29885191088 199 29885189691 4002502386 30773676142 7463505926 23130680797 30617693792 17085668681 22363171334 22377675195 12210508866 16991511620 12127457814 17211006625 3121501383 305...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
17210507896
17210507896
33946682372
35163191163
27379170855
27379171334
39375196452
27379171334
9046501383
17210507837
35823194285
35823194285
27457179645
9046501317
35823193927
12492004312
27379170848
27457179076
26266669449
27457179076
17210507896
9046501485
351...

result:

ok 

Test #24:

score: 10
Accepted
time: 0ms
memory: 8200kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
500000 100 10000 2 100
23563110896 19551607847 15326098079 5792588892 16565101743 17307606838 1301500802 12063597866 4397002030 5691005559 6597589725 19674609121 12062594807 12058594487 23710612088 16571604124 28077618265 4876503793 5792548773 30488623266 28077619241...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
33077612560
21572601743
10802503793
33077618195
33077614213
39485126271
33077612560
37565623512
13521088892
33077614213
10284502030
17064094487
33077613967
25017606327
33077614923
39485126271
35517622912
9750000802
17064094487
37565624969
10802503793
17064091963
3...

result:

ok 

Test #25:

score: 10
Accepted
time: 1ms
memory: 7916kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
500000 100 10000 2 100
6908543005 2238503286 13208053985 15680057439 24239066648 12970379595 17323563662 17323063417 6909043248 2243042488 6918047069 13205053732 26565068716 31814348865 6918048027 2210002506 29963344170 22615565814 17323063417 13211556372 31855352038...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
31805568018
14836548027
11918542952
11918542488
22323561103
14836548027
11918542488
18212052351
36855846284
18212052351
22323563474
22323558682
31805568018
22323557326
22323557326
7250000019
36631345373
22323563417
35019343547
27616565238
7250001633
35019343547
22...

result:

ok 

Subtask #3:

score: 20
Accepted

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Test #26:

score: 20
Accepted
time: 0ms
memory: 8504kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
47593 100 1 100 100
8236542 6929361 7732097 8203079 8592710 6467654 6576733 7542009 9527268 915443 6628467 7044554 6241526 1605461 1048168 1314047 327444 5313103 612660 9939386 9783364 8081165 5522602 3237428 7956261 8359505 6011187 153795 8329688 9695494 782518 8879...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
5091852
2427884
1423794
5275831
10125791
7334207
7967690
6337460
607236
6468819
1902134
6613162
1702804
5246675
8173614
3931309
3380304
2357970
4736704
2185679
8105449
6515658
6251324
5674678
4077727
252824
7120802
1694746
6733796
5050420
557776
3502646
7163786
72...

result:

ok 

Test #27:

score: 20
Accepted
time: 0ms
memory: 8800kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
453508 100 2 100 100
9554618 639918 6933450 6111089 540617 8738841 4677307 3564398 4989161 2801635 12702649 16266200 16064339 17547808 12046098 12082094 18499536 18867587 11991165 20177625 24939793 30636506 25006399 30189271 25378862 26198075 22386863 29756929 288040...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
966661
6870606
1162876
6660286
10438883
1130870
4377250
1276061
12208230
8210709
19107077
16435879
17816869
13490007
21522007
18720992
14613225
15953928
17876093
19157324
28383317
25550081
28494316
33347574
31297353
28313139
29966020
24698327
32632906
31918007
390...

result:

ok 

Test #28:

score: 20
Accepted
time: 2ms
memory: 8528kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
248156 100 1 100 100
9182715 3794036 4593405 8183311 6338387 315447 8642672 9378436 1365328 9966077 20952137 12991342 20504980 15387258 15137073 12863661 17057956 12515703 12500899 17680388 31518648 25668496 22965600 22431338 31880278 30381679 25439223 27491204 28526...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1032643
7948258
1631364
6704020
4929533
379155
10143144
5628216
6596728
5726523
11822307
13396089
11286635
12938920
18982200
12141973
22151839
20246283
11915041
20235542
22528397
31017387
23740221
29263724
23161218
30955458
28695196
27952076
24751655
26933862
4218...

result:

ok 

Test #29:

score: 20
Accepted
time: 0ms
memory: 10844kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
484301 100 3 100 100
6639190 3604855 2527749 1267642 9176438 1673413 6952781 9895691 2426362 434213 18257288 17988364 17020015 22622854 16855149 15459034 17253112 14000322 19130152 21166552 27120912 32757170 34389995 26715547 27812116 28817765 32012310 34872231 26131...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
3306050
2559722
13579819
11434431
3394976
8211091
2178800
3462782
9491995
10752025
24225973
25044243
14935804
16771281
20220478
16701669
21514803
26903615
16590657
18532653
32947327
30191770
34006389
40451619
31491143
36839134
35328709
40116746
28900766
32117738
4...

result:

ok 

Test #30:

score: 20
Accepted
time: 0ms
memory: 12912kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
472029 100 1 100 100
3099416 6053545 503906 9634810 4729443 6705661 9834974 7212800 5118880 7465653 17285702 14209342 19290663 20214413 19202621 17580555 14152753 16786172 14864594 11825865 23607555 22654182 30693695 27651417 25990807 28993935 24166129 26551364 28678...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
10173090
2042405
8405953
982208
6190675
6947851
8439703
11269953
9299832
5908620
16039078
14890227
21200656
19980728
19787405
17138789
20176169
14930504
15424470
14353064
30668056
24531024
24028227
33400289
24886047
26079555
33395622
23404653
33053840
27027706
376...

result:

ok 

Test #31:

score: 20
Accepted
time: 0ms
memory: 10656kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
484301 100 3 100 100
6639190 3604855 2527749 1267642 9176438 1673413 6952781 9895691 2426362 434213 18257288 17988364 17020015 22622854 16855149 15459034 17253112 14000322 19130152 21166552 27120912 32757170 34389995 26715547 27812116 28817765 32012310 34872231 26131...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
3306050
2559722
13579819
11434431
3394976
8211091
2178800
3462782
9491995
10752025
24225973
25044243
14935804
16771281
20220478
16701669
21514803
26903615
16590657
18532653
32947327
30191770
34006389
40451619
31491143
36839134
35328709
40116746
28900766
32117738
4...

result:

ok 

Test #32:

score: 20
Accepted
time: 3ms
memory: 8836kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
50884 100 2 100 100
306774 363330 178941 833338 949358 197445 630650 370609 797584 208264 4206030 4035269 4507758 4487377 4509864 3878828 4403929 4142666 4342281 4427731 8072541 8373247 7533523 7656633 7693460 8349100 7907319 7892285 8027749 7682020 11724627 11407168...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1289288
1050665
2456509
359277
2178004
194304
2927480
2968808
1348655
1519943
5909271
6415596
4320496
4141896
7506217
4191696
5305992
6776834
4611326
6227106
10921313
8000841
10420701
10921313
10111991
9526045
10808098
7796591
7764741
8325391
11953083
13661432
126...

result:

ok 

Test #33:

score: 20
Accepted
time: 0ms
memory: 12924kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
261650 100 1 100 100
516646 925152 620758 443019 623823 752420 253288 70790 990681 695683 13576702 13274940 13113048 12940822 13338419 12824465 13153781 13164650 13436689 12825533 25643732 25836068 25418081 25520933 25169410 25815586 24972142 25662839 25677636 253088...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
12090132
6621138
8545276
2785268
3002596
12198768
12701413
12731242
3417464
1516694
14548718
13109903
14944211
15702647
19938301
15827534
22859335
17464295
21503533
15827534
31910748
29113382
35798950
27815828
28432658
29968874
35209047
32621508
30828084
30828084
...

result:

ok 

Test #34:

score: 20
Accepted
time: 3ms
memory: 8536kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
47082 100 3 100 100
332975 785854 740246 290010 89703 453552 537375 270160 275966 962863 5259802 5916653 5447759 5376104 5708620 5359078 5090724 5003580 5448832 5697321 10514886 10063360 10184536 9937982 10464886 10429987 10406188 10338707 10373799 10240991 13998179 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
2237158
1763805
2480158
1763805
4024018
2686636
1051119
2686636
398883
4000160
8323074
6937114
5610137
8804082
8733126
5305368
8733126
9276597
8062257
7952201
10899716
13092797
10899716
13367642
11516811
13367642
10134461
10342541
11169965
11981891
14516262
172278...

result:

ok 

Test #35:

score: 20
Accepted
time: 3ms
memory: 10120kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
52428 100 1 100 100
409980 832602 368030 762834 933249 375269 481848 809365 785226 383171 3117441 3792596 3414710 3183217 3382432 3120450 3611101 3366268 3666047 3379082 5898864 5864313 5799286 5667570 5773894 5973403 5810196 5704175 6155658 5968846 8914796 8511987 9...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
2322405
870018
1770020
134610
646698
562358
562358
3116197
1569483
395846
4158915
5620263
4128213
5354546
4128213
4313451
4313451
4158915
5655793
4587877
6572409
6498216
7807474
8008524
7148705
7740194
7464899
6850001
8517518
7573947
9914130
10489717
10439767
8820...

result:

ok 

Test #36:

score: 20
Accepted
time: 3ms
memory: 8536kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
50884 100 2 100 100
306774 363330 178941 833338 949358 197445 630650 370609 797584 208264 4206030 4035269 4507758 4487377 4509864 3878828 4403929 4142666 4342281 4427731 8072541 8373247 7533523 7656633 7693460 8349100 7907319 7892285 8027749 7682020 11724627 11407168...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1289288
1050665
2456509
359277
2178004
194304
2927480
2968808
1348655
1519943
5909271
6415596
4320496
4141896
7506217
4191696
5305992
6776834
4611326
6227106
10921313
8000841
10420701
10921313
10111991
9526045
10808098
7796591
7764741
8325391
11953083
13661432
126...

result:

ok 

Test #37:

score: 20
Accepted
time: 0ms
memory: 12576kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
47082 100 3 100 100
332975 785854 740246 290010 89703 453552 537375 270160 275966 962863 5259802 5916653 5447759 5376104 5708620 5359078 5090724 5003580 5448832 5697321 10514886 10063360 10184536 9937982 10464886 10429987 10406188 10338707 10373799 10240991 13998179 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
2237158
1763805
2480158
1763805
4024018
2686636
1051119
2686636
398883
4000160
8323074
6937114
5610137
8804082
8733126
5305368
8733126
9276597
8062257
7952201
10899716
13092797
10899716
13367642
11516811
13367642
10134461
10342541
11169965
11981891
14516262
172278...

result:

ok 

Test #38:

score: 20
Accepted
time: 3ms
memory: 10620kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000 50 33 100 100
3333000 1666499 499949 1166550 3999599 1833149 499950 2499749 333300 4166249 2333100 2833049 3832951 3166351 1999801 2833051 3999600 1166551 3499649 2166449 1999800 999900 833250 2166449 833250 166651 2666401 333301 4166249 166650 1499850 3666299...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
7668186
4084804
6042150
4771604
3535364
6951185
6042150
7668186
6951185
4428170
5149276
8535807
4153484
4084804
5801736
8022760
5424064
6694576
6042150
7508703
7508703
6042150
11234559
4943304
4771604
3466650
9572036
3947410
5801736
6694576
7281453
7508703
8535807...

result:

ok 

Test #39:

score: 20
Accepted
time: 0ms
memory: 10552kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000 100 1000 50 100
3060005 6732000 22031994 6119999 16523997 9792000 4896004 22644006 11627996 17747993 28763997 25092004 29376003 2447995 13463994 27540001 23255998 10403993 22643994 15300001 4283995 9791998 22031997 19583998 17135995 4896007 11628005 3059993 183...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
46102206
24256679
36741998
19204700
43722765
46514000
30241533
36741998
27172739
14704239
35547999
43722765
44347126
21445685
43722765
43403994
35547999
27172739
19204700
40665134
42993230
22845075
30241533
38727654
36741998
14704239
30241533
31424005
40665134
437...

result:

ok 

Test #40:

score: 20
Accepted
time: 4ms
memory: 10368kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 80 10000 100 100
121212000000 27272700000 112121100000 93939300000 63636300000 9090900000 57575700000 87878700000 12121200000 81818100000 121212000000 69696900000 109090800000 33333300000 42424200000 81818100000 36363600000 60606000000 84848400000 1060605000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
202020100000
103030300000
103030300000
232323100000
236363600000
107070700000
193939300000
199999900000
226262500000
204040300000
208080700000
115151500000
260606000000
153535300000
147474700000
238383700000
218181800000
153535300000
318181800000
216161500000
3404...

result:

ok 

Test #41:

score: 20
Accepted
time: 3ms
memory: 8576kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 80 10000 100 100
56565599997 44444399998 121212000000 64646400002 113131199998 153535199999 52525199999 60606000001 141414000000 4040400003 32323200003 48484799999 52525199999 133333200002 117171600000 157575600002 60606000002 32323200000 101009999998 646464...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
372747199999
251505050008
222192230003
282806704875
116162832119
304041512149
201019716959
146468822415
228275164250
228275164250
291891777300
253525522035
145458661409
287854114564
304041512149
218152942153
158591274539
211090595981
152530068479
158591274539
1161...

result:

ok 

Test #42:

score: 20
Accepted
time: 0ms
memory: 10576kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 80 10000 100 100
111111000001 166666500003 161616000004 55555499996 5050500001 106060499998 131313000002 196969499998 50504999995 85858499997 181818000000 146464500004 121212000001 131313000002 171717000001 101010000000 95959500003 95959499996 10100999997 18...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
234350330675
149486011117
202000756067
169683940723
202000756067
255573096755
265695601897
393919222051
323182525116
236370358652
338353823076
133327683429
411100999998
265695601897
263674563805
147466165167
255573096755
216157145546
169683940723
265695601897
2050...

result:

ok 

Test #43:

score: 20
Accepted
time: 4ms
memory: 12616kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 80 10000 100 100
44444399996 121212000004 40404000004 32323200005 52525199995 4040399999 96969599998 36363600000 149494800005 157575599998 161616000005 84848399996 20202000004 52525199997 92929199997 84848399996 56565600001 153535199996 56565600004 141413999...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
280788304065
130314829190
150526990220
293920150121
200046587645
157601175545
191961737240
265655389845
299982678380
146484590030
241417252301
260605142942
191961737240
140420959730
293920150121
269697556065
182866281785
138399669590
260605142942
208031972103
1404...

result:

ok 

Test #44:

score: 20
Accepted
time: 4ms
memory: 12688kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 80 10000 100 100
30303000005 60606000003 65656500001 181817999996 181817999998 80807999996 40404000004 45454499995 191919000001 55555499995 101010000001 156565499997 161615999995 85858500003 45454500003 121212000004 65656499998 141414000002 70706999999 25252...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
310131000004
258633599728
197989002919
105050499998
130305555251
145458590403
145458590403
241404889048
204050228981
289936688773
226233772058
236386994336
161621756558
216202691106
316131986096
305100499998
393968856945
409140154911
271755424787
248523184807
3363...

result:

ok 

Test #45:

score: 20
Accepted
time: 3ms
memory: 10324kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 100 10000 60 100
288134700000 42372749996 338982000001 161016450003 101694599996 84745500003 152541899999 8474549999 423727499999 305083799998 237287400004 186440100000 152541900000 389829299996 228812850002 169490999997 110169149999 118643699995 84745500005...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
133893095273
242394633318
435602800004
411834477031
411834477031
376310949997
411834477031
435602800004
588095226568
377945938029
316909099996
283053252007
184730275803
545741950000
508463419527
479611555060
508463419527
181341063781
494874650005
316909099996
1203...

result:

ok 

Test #46:

score: 20
Accepted
time: 3ms
memory: 8288kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 100 10000 60 100
172880820002 55932029996 152541900000 183050280003 218643389998 66101489998 35593109997 122033520002 106779329997 152541899998 71186219996 30508379996 40677840003 127118249998 218643389997 223728120002 228812850004 193219740003 249151770001 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
244097709997
362681478579
135585532923
127113555279
337336472373
288162407530
322013469050
244097709997
237315776027
249186785636
272902764345
164390328891
196583977898
218679881597
167779181930
186417558739
279687449075
291552896027
116947076138
279687449075
1203...

result:

ok 

Test #47:

score: 20
Accepted
time: 3ms
memory: 8280kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 100 10000 60 100
355931099998 110169150005 262711049998 194914649999 313558350001 415252949998 50847300001 76270950003 322032900002 161016449998 118643699997 135592800001 423727499996 110169150001 305083800005 372880200003 59321850002 322032900005 3305074499...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
262715597269
133907093536
500047892380
427118249997
194948240232
172905586696
267805641484
344097239389
237273792692
359367800011
284757364521
528762849996
567745987613
377956875997
613508350001
623700101409
500047892380
550826379047
445809924934
530458815072
1220...

result:

ok 

Test #48:

score: 20
Accepted
time: 0ms
memory: 10364kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
10000000 100 10000 60 100
330507449998 42372749998 59321849996 347456550002 322032899997 262711049999 389829299996 203389200000 271185600005 194914650005 169491000002 152541900000 279660149997 296609249997 50847300001 228812850005 228812850000 398303850003 2457619499...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
479631953491
330527320942
266138318556
410129150003
598332602974
564434402978
316929100005
216934841712
122039263711
172906882623
227148080413
452585657593
294953644044
427108250003
454284574950
227148080413
140690711307
428783637032
479631953491
325433650001
2491...

result:

ok 

Test #49:

score: 20
Accepted
time: 0ms
memory: 12644kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
99 100 199999 100 100
12600000 16600000 16000000 6800000 1000000000000000000 14200000 2400000 12400000 2800000 9800000 13400000 2600000 7800000 14600000 18200000 4800000 18400000 13000000 15400000 17800000 200000 3400000 8000000 2000000 8400000 4400000 16800000 10600...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
28872358
30853627
37137028
23301150
39337323
35153991
35454181
37710069
38541453
38619759
39324199
30529430
36899924
36368753
20172361
31562446
20603024
35261526
31690758
26649745
1000000000019799894
30874777
38891303
37756560
32885590
36585635
23004224
25405904
3...

result:

ok 

Test #50:

score: 20
Accepted
time: 0ms
memory: 10300kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
138 100 199999 100 100
2200000 17200000 7200001 3400001 8400001 14000001 5600000 4400001 14600000 800001 12200001 17800001 13200001 10600000 13800000 4000001 200001 9000001 18800001 11800000 19200000 1000000000000000000 7600001 3000000 4600000 16200001 8800001 740000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
45112325
44514471
43621011
44585200
42378263
45231147
28712743
42811057
39534012
39519484
44270631
42799403
45805168
34444564
40249218
46609879
44254722
44761303
43154254
47156738
29128191
38541025
28001415
43528835
43588734
45131805
42432581
37145549
28459852
447...

result:

ok 

Test #51:

score: 20
Accepted
time: 2ms
memory: 8536kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
582 100 199991 100 100
4000008 10600001 9200007 13400003 12000003 18800003 7800007 5200001 18400001 18600002 15200007 11400007 3200002 11800007 19200008 2200010 5000005 16400001 6600002 12400010 17200000 7000009 13000009 16800007 19600006 19400009 4400005 5600009 820...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
131218828
127211305
132638123
135335154
135183842
121544435
135152389
130832007
135694043
134511078
134386060
134356304
133835026
133143374
128609744
131193334
134850347
123478409
129449191
135311759
131575903
128500444
135589552
135712766
124798499
133401988
1268...

result:

ok 

Test #52:

score: 20
Accepted
time: 3ms
memory: 12852kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2877 100 999968 100 100
60000023 65000002 6000020 45000037 77000034 8000022 11000002 19000012 22000032 27000004 74000024 44000024 81000031 76000021 18000048 98000026 90000007 83000045 7000025 34000043 2000046 40000033 14000050 87000033 78000010 91000031 86000002 7100...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
2892775977
2881964261
2964384265
2884617621
2959231822
2973792272
2959142515
2966745452
2972805361
2963921345
2974103405
2969030985
2954637129
2973897216
2922754158
2951091860
2891245823
2896242182
2968543553
2877052696
2960600243
2878939080
2969224401
2957350423
...

result:

ok 

Test #53:

score: 20
Accepted
time: 0ms
memory: 8480kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
765 100 999994 100 100
1100001 4600005 3500002 9000001 6700002 9600002 3800001 1200002 7500001 1300001 1000000000000000000 5300002 9500004 2300003 8100001 7300000 1700005 7600002 3700000 7900005 4900005 3300000 8700004 3400005 5100005 7400003 4400005 6200002 7000005 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
773338544
771447020
773212162
773359190
765021286
773096773
773429456
772846852
774782708
772441914
771541614
774377754
773100487
770621892
773288979
766661055
774449147
773536733
767612504
774509647
774614685
772494695
774126521
766863133
773684344
766097531
7679...

result:

ok 

Test #54:

score: 20
Accepted
time: 2ms
memory: 8596kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
745 100 99996 100 100
49000001 16000000 31000003 90000002 43000005 13000001 45000004 35000003 25000002 58000001 11000004 98000003 14000001 1000000000000000000 51000004 86000000 92000004 44000003 72000003 29000000 75000003 57000000 10000005 7000004 3000001 5000002 230...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
105159452
94646416
155112345
166648871
168019474
119192288
170982807
165070791
166488698
107701245
154891089
157881519
167155516
158842515
171907562
90326354
149296529
140201583
164329076
153427501
167243572
151386019
169253474
1000000000074497013
93018932
8609796...

result:

ok 

Test #55:

score: 20
Accepted
time: 1ms
memory: 3804kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000 100 1000 100 100
26512500 20452500 17422500 2272500 37117500 14392500 18180000 10605000 10605000 9090000 30300000 35602500 36360000 5302500 18180000 5302500 19695000 34087500 33330000 23482500 6060000 13635000 28785000 22725000 6060000 28027500 15150000 189375...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
113635000
107575000
122725000
134087500
132052087
117106539
124240000
132572500
137618773
137117500
106892036
123101388
127270000
137875000
114562188
112381536
103373700
120764808
130708047
107575000
122725000
132572500
154433759
113635000
153410263
134845000
1343...

result:

ok 

Test #56:

score: 20
Accepted
time: 0ms
memory: 3808kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000 100 1000 100 100
11362500 3787500 15150000 22725000 1515000 24240000 7575000 23482500 4545000 5302500 9090000 20452500 33330000 28785000 16665000 15907500 17422500 37875000 12120000 32572500 31057500 26512500 12877500 17422500 25755000 4545000 34087500 5302500...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
111362500
137875000
106717509
111362500
107328210
123482500
121164662
121210000
117422500
104545000
130784736
115767118
106610191
108332500
100757500
129582849
112120000
132572500
127922123
129542500
156216973
111362500
120659287
103793323
153185376
107575000
1225...

result:

ok 

Test #57:

score: 20
Accepted
time: 3ms
memory: 12644kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
148 100 1 100 100
2597 1813 3185 2499 196 980 1862 441 490 3969 2156 1764 4116 2450 4704 4410 3234 784 3920 1617 1176 2548 4459 4851 3136 245 2842 3724 1911 3871 1127 4606 1470 3577 1225 2303 1519 2205 931 4263 2058 3332 4655 1029 343 3283 2254 4018 539 294 2009 4214...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
167
171
166
181
179
180
203
205
161
243
160
172
154
189
195
151
209
211
158
215
178
168
223
205
175
191
156
223
235
190
157
170
225
237
184
163
165
231
176
217
227
152
150
227
196
153
229
185
183
159
188
162
239
245
186
241
249
207
199
187
221
233
229
237
201
235
...

result:

ok 

Subtask #4:

score: 26
Accepted

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Dependency #3:

100%
Accepted

Test #58:

score: 26
Accepted
time: 641ms
memory: 40412kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
495805 1000 1 1000 500
5585325 1705235 1140138 7651715 9805203 9566576 6138508 173503 2135137 2633968 3371940 1046050 8171384 5860140 8592836 4699790 8926855 206320 6853233 4234727 1743245 4414956 2282357 6191015 5317931 6204667 675473 7926324 9601618 2010480 653827 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
12368719
10650409
3628146
2786129
3362010
3184660
628541
4007713
2400253
11217515
3565040
2055619
4316784
6886973
4397603
6707148
9052220
11301272
1372112
4914319
2314506
8133412
3481711
4833338
8770654
719755
3724381
12539515
11159954
8410674
7893634
11365010
861...

result:

ok 

Test #59:

score: 26
Accepted
time: 501ms
memory: 40480kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
4867821 1000 2 1000 5000
7136001 5288195 6332139 7031269 1621605 3114463 7673536 5743640 9928257 523550 5078607 1266598 9450338 5177429 2217309 3824296 1659595 4320382 942250 6359557 4253813 1636568 4441276 3054972 9589332 3757406 3530575 9716720 1387768 6111347 7796...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
29094107
22181293
9963069
28395467
42309398
39063394
44594688
38208856
30439301
42065077
41873795
21377815
10304914
11760425
31348655
25639342
45855248
22181293
29433513
32803180
31348655
45062005
32393428
11470714
13090401
37308026
10713064
15242191
27516164
4716...

result:

ok 

Test #60:

score: 26
Accepted
time: 516ms
memory: 40748kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2579545 1000 1 1000 5000
3639017 5999405 4098261 7137476 7390770 6698681 5138691 2780941 4878121 5913237 8017519 5032338 2565746 5168430 507628 8107825 4521539 6159344 4719520 8710010 1188359 3115779 6730779 1982058 2866998 8227602 4734808 324799 467783 4166340 77916...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
23110500
17901804
22577373
4834969
10504941
13661867
21423410
2829810
16862100
8903441
4915796
16074279
4615314
25004951
21919576
15506609
21021966
11807386
22248276
12781459
13661867
7891304
9659611
10177019
24263180
5677668
8842791
13234565
17627924
4834969
2055...

result:

ok 

Test #61:

score: 26
Accepted
time: 525ms
memory: 40556kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
4953217 1000 3 1000 5000
9369813 3531945 4078754 4482063 5450139 2402287 7692043 2088607 1140028 106414 584337 696018 3299493 7030041 5997534 8412397 1088349 4627671 9904952 3633705 2526590 8159817 6975355 7437061 359739 8406261 8950618 930771 289467 9522495 7791144 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
23366576
50361003
49904757
57253737
20715597
67632408
22845374
69226420
16751457
56509891
68507123
30371406
38643262
45324887
23418055
29823166
59091702
22926986
60362552
65302233
19771050
26983791
31801246
35679295
52794904
29461413
27381575
56337290
28183917
529...

result:

ok 

Test #62:

score: 26
Accepted
time: 514ms
memory: 40440kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
5027792 1000 1 1000 5000
4402806 7756592 7800573 1283506 3300667 4632481 9027118 1297548 7241529 263201 6812022 2225945 2073719 3173231 7490726 6970920 7071105 6270950 6416053 5380984 4843666 3965596 3960116 2468289 7240251 7927176 9144863 2817007 5920918 8531575 589...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
35028167
26742869
36373159
16931529
30134740
23456937
21449722
37461830
32833846
8881313
6778152
8387265
19086917
37630081
22626980
20853702
10333427
8181767
31738302
39619186
32130505
32229297
30939546
13488957
14223284
9159391
11716686
35739334
27245789
6740754
...

result:

ok 

Test #63:

score: 26
Accepted
time: 509ms
memory: 40536kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
4867821 1000 2 1000 5000
7136001 5288195 6332139 7031269 1621605 3114463 7673536 5743640 9928257 523550 5078607 1266598 9450338 5177429 2217309 3824296 1659595 4320382 942250 6359557 4253813 1636568 4441276 3054972 9589332 3757406 3530575 9716720 1387768 6111347 7796...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
29094107
22181293
9963069
28395467
42309398
39063394
44594688
38208856
30439301
42065077
41873795
21377815
10304914
11760425
31348655
25639342
45855248
22181293
29433513
32803180
31348655
45062005
32393428
11470714
13090401
37308026
10713064
15242191
27516164
4716...

result:

ok 

Test #64:

score: 26
Accepted
time: 500ms
memory: 40484kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
4953217 1000 3 1000 5000
9369813 3531945 4078754 4482063 5450139 2402287 7692043 2088607 1140028 106414 584337 696018 3299493 7030041 5997534 8412397 1088349 4627671 9904952 3633705 2526590 8159817 6975355 7437061 359739 8406261 8950618 930771 289467 9522495 7791144 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
23366576
50361003
49904757
57253737
20715597
67632408
22845374
69226420
16751457
56509891
68507123
30371406
38643262
45324887
23418055
29823166
59091702
22926986
60362552
65302233
19771050
26983791
31801246
35679295
52794904
29461413
27381575
56337290
28183917
529...

result:

ok 

Test #65:

score: 26
Accepted
time: 584ms
memory: 40572kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
496711 1000 1 1000 500
149296 299734 502222 585328 396006 819065 176830 297944 74819 665203 709923 103339 907148 62014 735451 788623 616739 184576 903933 944195 84056 874415 307691 521636 308275 183181 159513 119468 676256 43486 331184 117711 835965 33474 837640 9576...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
24244247
23180483
16865435
13767693
14195623
17167897
18963105
23013491
24402460
14195623
22481897
26123746
21261587
20947125
14656649
23926774
20947125
22074661
9826812
12812513
14959242
13219029
16452640
21896904
19923375
22192518
10908583
24315368
16151756
1742...

result:

ok 

Test #66:

score: 26
Accepted
time: 464ms
memory: 40484kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
497170 1000 2 1000 5000
291929 832302 269785 577239 93809 202454 459635 707754 663281 180543 719673 311678 49985 445998 567025 932460 307049 402165 306394 342943 267838 941813 111547 881795 614059 792752 813466 948166 828783 893804 733434 377596 752084 289188 177286 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
27921259
9804496
17419757
5866212
28625067
17963288
5247944
26020842
13391772
19816248
9660212
17963288
30814172
23883854
1590896
16433942
8588204
8910764
22814522
17963288
22703556
6717748
18229970
19816248
5559052
3350624
9106204
20985692
15354047
4843664
273930...

result:

ok 

Test #67:

score: 26
Accepted
time: 451ms
memory: 40456kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2548051 1000 1 1000 5000
778812 874917 184104 14029 722748 876908 263156 698793 291269 534996 207118 232220 257007 711901 879142 874961 212352 944370 389273 723355 972175 788475 571304 454262 136541 890045 72713 572950 342830 653737 224767 884205 486275 492374 244418...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
27617690
11104810
20393310
7297170
82123352
28046710
78464358
122337613
104080837
82123352
63590763
21641730
107810271
128281870
121904837
100420887
47582548
99179911
44342839
68959569
39123064
39123064
26901850
63135112
122337613
28046710
124995634
98422343
86945...

result:

ok 

Test #68:

score: 26
Accepted
time: 470ms
memory: 40668kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
519402 1000 3 1000 5000
234237 750667 272546 6429 678659 653864 383820 638843 958747 386926 201556 203198 652946 566990 966778 448003 831666 253210 549355 817378 815184 168886 254028 47189 240515 819541 488447 701150 445031 120370 7463 977546 468140 69972 221017 2747...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
13269647
36137718
19658992
39451306
17704985
30184561
41834668
32576483
39451306
36479888
35671912
36137718
44465686
16668023
34909399
27508853
46105323
19555170
21565719
26594115
38445912
5358921
36749362
45688287
19658992
44779992
19012380
8148699
35671912
31739...

result:

ok 

Test #69:

score: 26
Accepted
time: 475ms
memory: 40464kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
510953 1000 1 1000 5000
809130 703003 250200 898000 272600 132844 679237 355398 18883 633241 673390 640677 583504 626777 712484 786910 595543 787861 380998 733275 994708 272160 291743 867132 189496 148326 590794 442303 347079 327636 648064 561852 53684 953302 400615 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
15886493
10159723
12156612
23270592
19699757
24960289
11578344
7683123
25103761
24515356
19378018
17311246
16664829
8349923
22596988
9034423
22501861
4431403
4966943
16053829
15218790
11716096
3175543
24299339
16493941
24960289
11376024
1391923
25632240
22291480
1...

result:

ok 

Test #70:

score: 26
Accepted
time: 475ms
memory: 40472kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
497170 1000 2 1000 5000
291929 832302 269785 577239 93809 202454 459635 707754 663281 180543 719673 311678 49985 445998 567025 932460 307049 402165 306394 342943 267838 941813 111547 881795 614059 792752 813466 948166 828783 893804 733434 377596 752084 289188 177286 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
27921259
9804496
17419757
5866212
28625067
17963288
5247944
26020842
13391772
19816248
9660212
17963288
30814172
23883854
1590896
16433942
8588204
8910764
22814522
17963288
22703556
6717748
18229970
19816248
5559052
3350624
9106204
20985692
15354047
4843664
273930...

result:

ok 

Test #71:

score: 26
Accepted
time: 463ms
memory: 40600kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
519402 1000 3 1000 5000
234237 750667 272546 6429 678659 653864 383820 638843 958747 386926 201556 203198 652946 566990 966778 448003 831666 253210 549355 817378 815184 168886 254028 47189 240515 819541 488447 701150 445031 120370 7463 977546 468140 69972 221017 2747...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
13269647
36137718
19658992
39451306
17704985
30184561
41834668
32576483
39451306
36479888
35671912
36137718
44465686
16668023
34909399
27508853
46105323
19555170
21565719
26594115
38445912
5358921
36749362
45688287
19658992
44779992
19012380
8148699
35671912
31739...

result:

ok 

Test #72:

score: 26
Accepted
time: 3ms
memory: 27964kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000000 1 70000121 1000 5000
100000000000
70001123
0 1134946 1234453 2496589 4015353 4621347 5213369 5934475 5963688 7235349 7866734 8716738 9789162 9815432 10104811 10942871 11060429 11536421 12317498 12992150 13104946 14830225 15007146 16366617 16810059 17102831...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
70000380412400424
70000692168140370
70001044785646728
70000543464124968
70000950229534974
70001135615188218
70000442732846532
70001132873613012
70000495589637108
70000942482691212
70000253482412154
70000489622654964
70001015994247866
70001179412385774
700009936839...

result:

ok 

Test #73:

score: 26
Accepted
time: 3ms
memory: 8104kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
20000000 1000 991 2 5000
849172344874 964584239787 849172349715 375438471913 752492300965 521147112799 726121746274 421978496929 596647151778 391438481247 319618455147 392458481596 498667091231 116500049241 849172339909 671661133038 647666808163 394758485878 97454425...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
496575573946
268591071777
999084265960
217911050964
268591071777
603507139369
415698490900
546627113882
342858454522
527207099579
45220004013
363078458517
994384245979
798392313007
460598498606
999084260838
875872355752
69780013290
70240016717
193580066672
2379910...

result:

ok 

Test #74:

score: 26
Accepted
time: 277ms
memory: 34560kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000 500 33 1000 5000
10075065 10240233 21306282 40465425 15690677 33858824 5780774 9744734 23948927 39804762 8423415 40795755 12882869 1651653 21636618 15030013 24114088 1321319 3798795 6771767 21471449 30390363 35510477 14039025 18498481 35675641 4789787 1238737...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
68238175
55563512
44460478
44556542
60938942
74588571
80936730
79840863
83753805
75436460
82795813
49137150
73249137
66654718
35267326
54069950
43659678
43915806
45645694
67249110
36932926
64122152
80641668
43915806
83753805
73803887
91736590
36100126
64662572
715...

result:

ok 

Test #75:

score: 26
Accepted
time: 306ms
memory: 25976kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000 1000 1000 500 5000
98000002 479999996 369000010 259999992 193999995 359000000 389000007 424999997 99000007 132999990 255000001 83000000 375000009 7999995 384999996 69000006 107999997 450999991 396999991 284000003 256999999 273999994 72000006 384000003 31600000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
225958338
497100007
683700003
555199992
300400000
159449188
624781553
196823588
526299992
165206436
152696946
103982994
287735261
246889531
689900000
626300006
115908012
541681952
374499995
355600001
486899995
544101861
460399998
557099998
341582361
253977376
4715...

result:

ok 

Test #76:

score: 26
Accepted
time: 662ms
memory: 40460kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1000 10000 1000 5000
820820000000 1749748000000 1249248000000 1473472000000 1805804000000 380380000000 664664000000 1997996000000 1721720000000 1665664000000 1457456000000 700700000000 472472000000 1785784000000 1881880000000 1141140000000 1637636000000 236...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1422422000000
2525524000000
2525524000000
1052052000000
2163162000000
2669668000000
1020020000000
1706706000000
1392392000000
3232232000000
1412412000000
1210210000000
3388388000000
1460460000000
2445444000000
1926926000000
1276276000000
2569568000000
184884800000...

result:

ok 

Test #77:

score: 26
Accepted
time: 661ms
memory: 40472kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1000 10000 1000 5000
1876874999999 90090000003 610609999997 2202200000001 430429999998 870870000002 1926925000002 580580000003 485484999998 440440000000 225224999999 1116115000003 1176175000001 45044999999 1411410000001 820819999998 1286285000000 4104100000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1266318252201
3148345859607
3490689999998
2268040793996
2133833570910
4301600000002
2538517890195
3785485000001
2079238179991
3700500000001
2191053732807
2451424644695
2370132874100
1631756335203
4068766360592
2688418902207
3473471059998
2982690619895
371381095980...

result:

ok 

Test #78:

score: 26
Accepted
time: 670ms
memory: 40432kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1000 10000 1000 5000
255255000001 1586584999996 880880000005 1956955000003 1021019999996 2347344999997 1821819999995 1706705000002 740740000002 145144999999 1296294999997 190190000000 2442439999997 170169999995 1026025000000 1576575000003 695695000005 15015...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1025016962008
1951572191608
3701200001503
1113069716812
2164430717401
3853651999996
3635335000002
3295994600896
2348185778917
1265160866008
1010007948016
2618716909803
1341206475592
1495298754016
4126124999998
1222135113196
3964260739402
1006005619588
332592480119...

result:

ok 

Test #79:

score: 26
Accepted
time: 333ms
memory: 40468kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
999 1000 199999 1000 5000
40600000 82800000 43400000 16400000 74800000 9200000 96200000 118800000 28000000 78200000 78600000 141800000 175200000 178000000 153400000 82000000 159600000 13400000 48000000 153600000 95600000 59600000 63000000 135400000 22200000 46600000 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
397323237
391976657
381264513
386605711
386675288
260884606
398978795
311963594
393116035
369723703
374978466
384962176
375470024
386505703
378790956
388735803
349821597
375398518
391294990
398039946
360960556
255852247
395941527
231611463
390549597
378439013
3577...

result:

ok 

Test #80:

score: 26
Accepted
time: 329ms
memory: 40644kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1492 1000 199999 1000 5000
42200001 111600001 43000001 160400000 36000000 38800001 60200001 61200000 193800001 164600001 94400001 170400000 136400000 84000000 14800001 130600001 185000000 54600001 107800000 64000001 136000000 172000000 114600000 68200001 117800000 15...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
402940402
495965601
354284122
469210281
486250385
445986963
361020218
472423635
463290939
482007070
451983596
449461024
350242014
360745970
486620388
350712521
484758705
474988357
490404744
477345027
463740438
482515794
464921048
455032461
459761492
463109955
3702...

result:

ok 

Test #81:

score: 26
Accepted
time: 327ms
memory: 40452kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
5932 1000 199997 1000 5000
129200000 174200008 164800003 145200005 132400008 55000008 153800009 82800001 31800001 187800005 72600008 117600007 137200004 6200001 35400004 160400002 98000002 116800010 171000005 9200009 164400006 40800010 188200002 194400007 30400009 79...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1351966067
1360519670
1381898945
1314478421
1370140367
1286294275
1347228653
1372404345
1370021184
1378890384
1382990020
1365340552
1193509548
1359205793
1276901945
1347135738
1335968245
1344995533
1234664880
1311123701
1381104555
1351715167
1347782543
1347867467
...

result:

ok 

Test #82:

score: 26
Accepted
time: 416ms
memory: 40456kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
30207 1000 999988 1000 5000
51000026 919000032 932000037 636000040 182000012 858000037 0 388000037 533000006 133000032 500000020 253000003 81000005 630000046 915000036 971000049 63000006 759000006 432000002 842000042 681000022 943000036 791000025 713000007 840000005 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
31191626198
30991948667
31162763953
30895524655
30993485134
30776268729
30957413079
31129625988
30679193052
31149066328
30881034719
30995772127
31120515499
31073891035
30299718090
30356975678
30839688762
31058226617
31070403788
31167492586
30472696244
31128178405
...

result:

ok 

Test #83:

score: 26
Accepted
time: 325ms
memory: 40468kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
7438 1000 999994 1000 5000
41600004 78600000 88400004 100004 44000004 22400005 16900000 87400002 39500005 93800001 61800005 48000000 12800004 53500002 62600000 24900001 61500001 83000001 47800003 35000002 33500001 31300000 61200004 53900004 37300002 62500003 19400004...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
7457739757
7516773768
7456341160
7454954071
7496072997
7467725013
7515367527
7447177587
7537585084
7465641748
7492410041
7531181831
7513628543
7526950785
7527562482
7531916112
7515842894
7521301605
7533956740
7521619460
7442487957
7513463057
7523039994
7467381784
...

result:

ok 

Test #84:

score: 26
Accepted
time: 329ms
memory: 40556kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
7469 1000 99994 1000 5000
914000004 115000002 680000002 275000001 32000005 315000002 965000002 612000002 455000005 261000000 573000004 542000003 811000000 864000002 797000003 930000004 716000000 131000001 243000001 48000000 983000002 52000003 833000000 614000001 6600...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1692024188
813731221
1391347920
1552676385
1574328727
1057247374
1030545713
1003138045
1013548288
1600465834
1634382125
1711720990
1674652275
1501987940
1570370729
1550595113
1181347266
1674700512
1724247663
1510276799
934476151
1511248660
1597653007
1660391422
17...

result:

ok 

Test #85:

score: 26
Accepted
time: 1ms
memory: 4188kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000 1000 10000 1000 5000
287000000 316000000 462000000 236000000 45000000 16000000 377000000 241000000 87000000 94000000 276000000 475000000 35000000 227000000 18000000 285000000 240000000 121000000 6000000 316000000 26000000 222000000 390000000 459000000 22700000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1195000000
1331002650
1163743095
1129000000
1379257035
1449000000
1281750334
1471009438
1141000000
1062000000
1439000000
1297000000
1021084635
1485920293
1367000000
1510731038
1392394964
1203000000
1394441443
1065859420
1244046618
1295000000
1290377504
1462881235
...

result:

ok 

Test #86:

score: 26
Accepted
time: 1ms
memory: 4160kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000 1000 10000 1000 5000
262000000 280000000 53000000 222000000 177000000 223000000 384000000 455000000 167000000 328000000 449000000 41000000 226000000 187000000 327000000 193000000 147000000 261000000 130000000 402000000 433000000 497000000 413000000 448000000 4...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1062287098
1303016072
1205000000
1080871065
1418000000
1121157651
1429000000
1418850783
1491273091
1355000000
1229000000
1381446718
1256000000
1215000000
1370000000
1700296427
1440000000
1028000000
1273855246
1113000000
1209000000
1489467421
1102960647
1223000000
...

result:

ok 

Test #87:

score: 26
Accepted
time: 2ms
memory: 3872kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000 1000 10000 1000 5000
532500000 198750000 246250000 610000000 552500000 107500000 166250000 490000000 517500000 518750000 187500000 266250000 110000000 145000000 401250000 271250000 176250000 261250000 212500000 427500000 228750000 415000000 521250000 408750000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1249288624
1078688082
1272500000
1336945060
1486052231
1001897623
1662162956
1704062118
1220000000
1495000000
1674838507
1870219278
1243750000
1256250000
1456249070
1330111088
1488750000
1490468411
1496250000
1169560281
1093750000
1621250000
1692895412
1487500000
...

result:

ok 

Test #88:

score: 26
Accepted
time: 453ms
memory: 40668kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1498 1000 1 1000 5000
144710 106786 55888 271456 347304 269959 395707 335328 328841 169161 148702 321855 409679 247504 45908 144211 102794 105289 315368 108782 419659 299400 333831 30938 421655 10978 279440 252993 132734 321356 396206 376246 432633 270458 215568 1497...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1828
5246
6394
5963
4300
3705
2733
5464
5783
5977
6322
5559
4591
5276
6332
5773
5164
6310
3727
2567
4881
5655
5404
2549
4827
5553
4753
4448
1586
5232
4941
4230
4202
4100
5613
2545
5206
4811
5212
5012
4983
4472
2047
2411
2781
3561
5721
2591
3088
2223
2045
2739
6300...

result:

ok 

Subtask #5:

score: 35
Accepted

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Dependency #3:

100%
Accepted

Dependency #4:

100%
Accepted

Test #89:

score: 35
Accepted
time: 702ms
memory: 41744kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
504630 1000 1 1000 100000
5338868 5262896 7336207 9459966 43167 8355734 2033651 218899 8336856 3572272 7198544 7482921 526012 2636223 9855421 9815752 5160311 5237691 6449394 2267058 6332047 9277761 3143900 9126549 1677015 5639334 7451932 3359597 2530924 7344417 26056...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
7332880
4475124
648842
6024847
6735488
9243129
7303967
1629945
2526481
11584971
7694312
8190114
10506769
10373008
7457919
9453339
6701475
11236592
11941806
6417676
5201808
1190878
678825
7303967
6459220
9078788
10811891
7730550
2916063
3563610
12452852
12207096
10...

result:

ok 

Test #90:

score: 35
Accepted
time: 837ms
memory: 55600kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
4989694 1000 2 1000 1000000
7189295 6589034 207948 1726925 9136422 4337676 5193675 1295078 252753 7611483 2090326 5790591 8091087 9033190 2323297 9990520 3951598 9299075 9282591 4194262 8521365 8613591 723851 8357444 5911896 2005350 547603 2725663 1075540 7446801 771...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
48070145
16952777
21794844
42141203
29176919
21683924
11592946
19048956
22298148
30807918
21683924
40603461
15162364
15438354
41862999
11897917
45751252
14136932
14690498
21314619
35424306
45175865
21827326
38760006
27511744
29477514
30534702
46431003
29950310
348...

result:

ok 

Test #91:

score: 35
Accepted
time: 841ms
memory: 56216kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2551695 1000 1 1000 1000000
3904631 1723300 292157 9120558 698643 8341545 9888088 719695 1043131 3930270 9233071 4763664 9388537 2380863 138118 2180072 4272376 2181917 9208342 6123075 1157777 8810765 6613296 1238596 1389981 5796410 1432372 4919968 457165 6269305 4904...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
12915272
19652237
23882578
15160015
19584473
19327807
8515203
8763521
12760690
8394877
24796932
11874651
10257709
23260554
10076686
9669726
7044787
9521983
19891610
9307291
15405891
16635134
23766378
20632971
7365889
18771003
22943000
22759932
17402314
9957343
943...

result:

ok 

Test #92:

score: 35
Accepted
time: 827ms
memory: 56100kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
5008664 1000 3 1000 1000000
1691800 1236782 9035329 8749651 1254300 6375141 488849 1622577 6380340 6138052 5308206 601854 3627645 9738508 9618663 2219611 7740223 4664926 9644819 2672453 1362009 5827611 4263625 9053818 7985104 1812917 6272151 2295587 4128181 5353657 8...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
35167340
65422735
67354003
40998200
15082610
17066896
36731249
55417735
16369118
40558161
48618459
18471483
40018447
59653326
60798574
37830646
18587764
23700901
34525628
58936214
52455075
36147258
40287316
38885075
35586714
57954888
49267488
55384443
17248399
341...

result:

ok 

Test #93:

score: 35
Accepted
time: 858ms
memory: 56044kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
4900595 1000 1 1000 1000000
4818628 5350921 5743405 1555022 5223629 655753 3787154 5383022 2583944 6005519 1259380 3999316 6329577 692854 8933785 8127376 2486670 6372004 8209079 4709135 6878994 2521223 9236997 9120832 2440938 3352051 8669531 167567 1095903 2854753 75...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
19926524
28682368
5673208
24168620
17517099
15529614
18335379
25740551
30476283
27866391
33234079
16008436
19650672
26949952
6840635
31641775
32201534
17164709
26066039
19129023
22147012
16697962
12466172
30212477
15809764
37089859
8135074
20564146
8233351
1858887...

result:

ok 

Test #94:

score: 35
Accepted
time: 834ms
memory: 55888kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
4989694 1000 2 1000 1000000
7189295 6589034 207948 1726925 9136422 4337676 5193675 1295078 252753 7611483 2090326 5790591 8091087 9033190 2323297 9990520 3951598 9299075 9282591 4194262 8521365 8613591 723851 8357444 5911896 2005350 547603 2725663 1075540 7446801 771...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
48070145
16952777
21794844
42141203
29176919
21683924
11592946
19048956
22298148
30807918
21683924
40603461
15162364
15438354
41862999
11897917
45751252
14136932
14690498
21314619
35424306
45175865
21827326
38760006
27511744
29477514
30534702
46431003
29950310
348...

result:

ok 

Test #95:

score: 35
Accepted
time: 809ms
memory: 55712kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
5008664 1000 3 1000 1000000
1691800 1236782 9035329 8749651 1254300 6375141 488849 1622577 6380340 6138052 5308206 601854 3627645 9738508 9618663 2219611 7740223 4664926 9644819 2672453 1362009 5827611 4263625 9053818 7985104 1812917 6272151 2295587 4128181 5353657 8...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
35167340
65422735
67354003
40998200
15082610
17066896
36731249
55417735
16369118
40558161
48618459
18471483
40018447
59653326
60798574
37830646
18587764
23700901
34525628
58936214
52455075
36147258
40287316
38885075
35586714
57954888
49267488
55384443
17248399
341...

result:

ok 

Test #96:

score: 35
Accepted
time: 629ms
memory: 41764kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
509253 1000 1 1000 100000
590358 402213 901116 157938 264021 589323 557873 932417 214930 53679 358992 398697 905295 897223 826638 240682 300905 886579 432383 682905 923509 445993 804283 946107 75125 519110 88829 939029 24513 257610 939496 575882 110455 581627 33740 4...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
21087843
15186106
23244937
5494829
25713040
23732955
16556712
14820587
17209011
13098048
25916340
23244937
25832365
20790249
25832365
21087843
12259566
10964294
11516595
11516595
16505100
25308898
14294952
24949404
12961928
17982426
19772544
18954314
25308898
1548...

result:

ok 

Test #97:

score: 35
Accepted
time: 835ms
memory: 55968kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
496181 1000 2 1000 1000000
185765 786503 504058 974167 719899 827353 172172 512343 250494 197414 337104 276411 664524 753142 951950 194790 165518 28047 160695 869357 870630 480943 197931 147915 425267 546074 170794 624327 178646 837989 627695 565271 539996 42036 6496...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
12740749
28473630
14993496
15738051
13548633
28571586
10663737
16736537
26326828
6679813
7868357
14554337
8147517
4363877
18071057
18071057
8271277
12513193
4990041
6908461
3522449
24926590
23424280
29759478
27692917
25343504
17998962
24406918
22116781
7504049
352...

result:

ok 

Test #98:

score: 35
Accepted
time: 776ms
memory: 55892kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2596986 1000 1 1000 1000000
284824 376474 563979 422656 897029 866788 553690 726563 67650 984410 189993 559719 841948 908350 946819 533019 455815 136154 346544 90039 456304 250469 369292 543485 696234 638856 193859 829045 139661 925833 923253 872190 896364 313493 222...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
36537814
77321194
94501235
44054347
84167284
54450807
83915378
16769777
78822002
78822002
28959227
30830803
131338105
98770738
89185121
110415192
73555668
29798438
69049837
78181334
84521552
79057656
66953185
33841619
23748116
16025509
118410270
85393700
56856241
...

result:

ok 

Test #99:

score: 35
Accepted
time: 801ms
memory: 55968kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
509450 1000 3 1000 1000000
590580 676009 917402 836159 681191 469279 73859 701752 800609 565121 416544 729798 333396 947831 149080 870104 267457 794690 300685 504204 55820 822837 147306 527892 821739 20505 157326 760379 828741 255142 97500 920410 189374 198366 113515...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
45387049
48295277
23190454
21418325
34221882
47774819
18357606
41754736
18357606
2629535
7377893
42761724
11050106
28516193
24365729
23113594
8571254
36401571
31539460
28516193
19815702
7377893
29605248
27589371
30570920
36401571
41520814
36401571
19067562
4276172...

result:

ok 

Test #100:

score: 35
Accepted
time: 819ms
memory: 55844kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
509416 1000 1 1000 1000000
758958 166877 110890 306627 484565 85725 969771 420167 832949 45655 655580 449676 168445 860910 780161 444969 357505 979646 375268 655458 997337 697156 89732 918671 786189 934138 711941 216897 587727 599732 383548 549836 982273 218921 41577...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
10234422
11929791
4037021
19290294
17406541
21330679
22528645
16097005
10405456
15623994
24820765
5893758
19908608
4668315
11397784
19213686
25447176
6041654
17222743
6177333
10234422
19213686
15157660
19988420
3296724
1259734
24820765
7244924
2847355
21265575
162...

result:

ok 

Test #101:

score: 35
Accepted
time: 815ms
memory: 55852kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
496181 1000 2 1000 1000000
185765 786503 504058 974167 719899 827353 172172 512343 250494 197414 337104 276411 664524 753142 951950 194790 165518 28047 160695 869357 870630 480943 197931 147915 425267 546074 170794 624327 178646 837989 627695 565271 539996 42036 6496...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
12740749
28473630
14993496
15738051
13548633
28571586
10663737
16736537
26326828
6679813
7868357
14554337
8147517
4363877
18071057
18071057
8271277
12513193
4990041
6908461
3522449
24926590
23424280
29759478
27692917
25343504
17998962
24406918
22116781
7504049
352...

result:

ok 

Test #102:

score: 35
Accepted
time: 797ms
memory: 55772kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
509450 1000 3 1000 1000000
590580 676009 917402 836159 681191 469279 73859 701752 800609 565121 416544 729798 333396 947831 149080 870104 267457 794690 300685 504204 55820 822837 147306 527892 821739 20505 157326 760379 828741 255142 97500 920410 189374 198366 113515...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
45387049
48295277
23190454
21418325
34221882
47774819
18357606
41754736
18357606
2629535
7377893
42761724
11050106
28516193
24365729
23113594
8571254
36401571
31539460
28516193
19815702
7377893
29605248
27589371
30570920
36401571
41520814
36401571
19067562
4276172...

result:

ok 

Test #103:

score: 35
Accepted
time: 846ms
memory: 49904kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000 500 33 1000 1000000
19918896 13576566 4558559 23189164 8423418 21603583 5747738 3567565 17243226 15360345 20612590 594590 17441421 9513507 16648627 4459451 12981969 16450430 11297284 5153153 15954938 19423401 15657643 9612608 7927919 15360346 8423416 10900886...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
35348469
35012021
34703685
41794825
51016037
69275382
89944874
63816912
95270191
49362497
43981093
36861981
69275382
35909085
65237221
43560785
37674737
69275382
67081244
51016037
43560785
79260302
38879913
53762893
59424633
64510704
66212402
63416548
60461473
592...

result:

ok 

Test #104:

score: 35
Accepted
time: 1001ms
memory: 42384kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2000000 1000 1000 500 1000000
464927996 2372735997 7967903977 2404799988 2084160046 609215984 2276543953 4825632045 7166304003 4761503991 3543071981 5098175990 416831951 6092160045 6589152007 3174336012 2549087958 6557087950 3462911993 4504992017 6637247971 783964802...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
10800853593
10111408137
8439668570
10261625410
2044271441
9124173001
8076180625
7404751993
12037248143
9238835282
9190415726
5916783932
9768935258
10868560352
6200831358
5444172025
9009912737
9440137551
2789138893
6861530422
6178135240
3022590553
8765439954
914183...

result:

ok 

Test #105:

score: 35
Accepted
time: 1454ms
memory: 55972kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1000 10000 1000 1000000
680680000000 870870000000 270270000000 1921920000000 1316315000000 460460000000 2337335000000 1556555000000 1456455000000 2392390000000 525525000000 1046045000000 500500000000 895895000000 1341340000000 2042040000000 930930000000 199...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
2402401000000
1611611000000
2606605000000
3530530000000
2032031000000
3141140000000
3235235000000
3690690000000
1051051000000
1185185000000
3318316000000
2756755000000
3105105000000
2644643000000
2158157000000
3110110000000
3440440000000
2372371000000
255655500000...

result:

ok 

Test #106:

score: 35
Accepted
time: 1442ms
memory: 55860kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1000 10000 1000 1000000
501500999997 642641999998 687687000000 282282000000 630630000000 807806999998 471470999999 1099098000003 72072000002 909909000000 1129128000002 831831000002 1393392000002 714713999998 114113999999 150149999997 963963000003 4744739999...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1479431332399
2375249665793
2789830252189
1709638309399
1929836337394
3708908000000
2966958173203
2574615612598
1172155063099
2886851194908
2468414576502
1502452050097
1730657227297
2417299882799
2123298946005
1809728319397
2574615612598
2123298946005
214239801679...

result:

ok 

Test #107:

score: 35
Accepted
time: 1413ms
memory: 56136kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1000 10000 1000 1000000
488487999996 1601600000002 1769767999998 652652000004 344343999995 1281280000005 888888000004 352351999998 568568000004 108107999996 612612000003 196195999998 872871999998 1593592000005 580579999996 924924000004 1721719999996 6046040...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1553443480581
1075061146187
1604484240387
2768701144302
1901721760991
1862690608783
3714212461013
1454364280385
1072058686799
3887183659398
1276221935981
3096595999996
2416531296207
1351281870991
2795815870894
1021017936991
1762610568795
1641513852983
122918429539...

result:

ok 

Test #108:

score: 35
Accepted
time: 1442ms
memory: 55892kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1000 10000 1000 1000000
984984000001 1213212000001 1231229999996 981980999995 777777000000 789789000000 1030029000006 495495000000 180180000008 1333331999992 384384000001 912911999999 486486000000 567567000002 48048000005 1396395000000 132131999999 10360349...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
2705256381023
1209188419395
2416116040008
1497447590595
2830648539601
2344433680569
2426527572436
1929836367393
2383774630478
1983884951994
2014714871199
1529476307403
1085076721806
1128115487499
3143943999992
2445200376598
1083075011997
1050045235305
140036028029...

result:

ok 

Test #109:

score: 35
Accepted
time: 1419ms
memory: 55900kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000000 1000 10000 1000 1000000
1649648000001 616616000003 1353351999994 4003999991 192192000001 220220000005 196196000006 1341339999993 448447999994 120119999994 732731999998 544543999996 1353352000007 1469467999992 1189188000008 256256000003 1761759999998 1485483...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1787865848690
1649713924879
2969533926325
1406446590578
2115650434271
2201798217555
2455506461001
2231444394189
2928510083411
1437480753684
2532754673531
2947507361841
1146160654587
2096693237555
2639696278269
1686754698586
1524576512389
2864254041710
180588564048...

result:

ok 

Test #110:

score: 35
Accepted
time: 743ms
memory: 55708kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
999 1000 199999 1000 1000000
105800000 145000000 172800000 61600000 187000000 153000000 176200000 78600000 88800000 158600000 50400000 181200000 91400000 76200000 42600000 25600000 158000000 113400000 100200000 113000000 144000000 1000000000000000000 3200000 11160000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
399188661
346096595
355934537
261873511
397781977
290227887
356202838
358576753
391183852
363296235
382158779
392044868
250113333
232844547
363584318
377078122
286083011
200265150
301980313
362710704
355567272
386611892
269323550
306368354
332081240
398011672
3981...

result:

ok 

Test #111:

score: 35
Accepted
time: 767ms
memory: 55788kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1516 1000 199999 1000 1000000
165200000 85800001 100400000 167800001 73200000 116400001 10800001 107400001 97400001 57800001 34600000 29600001 17800000 5000000 64200000 148600000 67600001 180400001 150600001 158600000 50400000 23200000 29800001 33000001 148800001 109...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
471317949
420568299
394129205
482703982
476545877
495819950
436385838
334385646
489054437
330369715
416344370
359502923
485809476
462740275
485039746
477901487
404184549
334551897
339626172
401779629
502670991
482413630
468230713
377417486
320767196
334491063
4945...

result:

ok 

Test #112:

score: 35
Accepted
time: 942ms
memory: 55808kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
6032 1000 199991 1000 1000000
117400000 91200002 85400008 86200005 3600002 188400002 68800003 9600006 60800004 69600002 165200003 195000004 85200004 148600004 120000008 40200007 108800007 114800005 94600006 24800001 7800005 36800005 69000000 54800010 198000001 444000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
1283609075
1361584611
1382376220
1403313666
1373130105
1372816205
1371925409
1308811507
1388225169
1267834131
1336339906
1379234741
1297440194
1405230090
1389250754
1230027107
1394649999
1376132163
1283584563
1210361734
1268252223
1391286111
1361564051
1394955949
...

result:

ok 

Test #113:

score: 35
Accepted
time: 1254ms
memory: 55704kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
30455 1000 999957 1000 1000000
706000002 484000037 302000003 385000031 230000027 445000005 22000016 237000014 837000038 220000023 923000028 36000037 809000040 361000010 159000013 954000036 905000010 273000039 887000020 76000029 816000049 446000007 876000005 637000016...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
31304845221
30762137136
31224284839
31348268550
31000102201
31368577415
31418311246
31374884335
31308786869
30993153026
31094251803
31433137780
31279529784
31144787081
30942187640
30909907570
30744767713
31223861862
30846807688
31212466853
31214468062
31297516659
...

result:

ok 

Test #114:

score: 35
Accepted
time: 894ms
memory: 55792kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
7556 1000 999998 1000 1000000
47700002 19800004 23300003 80500004 53800002 71900005 65400004 48300002 27000003 9100002 52200002 59100003 99800005 60000002 59000004 19900004 46800003 82700004 1600004 31400003 97800000 29100002 50600000 8600004 58100005 70200004 482000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
7631708069
7644298323
7652091780
7633711230
7638295395
7635544259
7642608851
7571430737
7647559403
7645681139
7595737085
7651881144
7566991249
7638581069
7652614710
7618405312
7593754203
7588695150
7575510448
7647070426
7643368186
7590723300
7642555248
7651285241
...

result:

ok 

Test #115:

score: 35
Accepted
time: 774ms
memory: 55600kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
7474 1000 99996 1000 1000000
482000004 262000003 493000001 281000000 211000005 435000004 779000002 81000005 760000000 174000005 507000003 240000004 383000001 777000001 601000001 830000003 193000000 379000001 279000004 194000002 967000003 2000004 630000004 528000000 3...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
852143939
1036104147
1686870401
804758107
1700658957
1644952900
1437224608
1510488387
957923149
1496173725
927393490
1378244651
1575867447
1667521737
1331520093
1609784768
1593670851
1581484451
1727714568
1642663003
971360397
1262946547
811183920
1223721106
146785...

result:

ok 

Test #116:

score: 35
Accepted
time: 131ms
memory: 18872kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000 1000 50000 1000 1000000
14414400000 8220712500 15765750000 3003000000 6156150000 1614112500 225225000 16516500000 2252250000 11711700000 12087075000 2927925000 1876875000 7432425000 1726725000 10135125000 1839337500 2777775000 11861850000 12875362500 72072000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
63175662500
66722369855
60894443298
53866362500
67053198519
55919859197
56457314093
63288275000
66707307618
69483062911
66401673615
54316812500
65956530708
52395311538
62312300000
51501500000
50347902918
58821312500
55183538006
51586713669
76094381155
50402109792
...

result:

ok 

Test #117:

score: 35
Accepted
time: 123ms
memory: 18936kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000 1000 50000 1000 1000000
20020000000 17167150000 11311300000 2702700000 22072050000 23423400000 21821800000 8108100000 4854850000 5205200000 23873850000 7057050000 21571550000 12712700000 1751750000 11011000000 5605600000 16266250000 21421400000 24874850000 83...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
55255250000
74074050000
58020700989
60060050000
73539324029
50878213046
59659650000
64430436979
71371350000
61988803443
63502732040
62244577701
73307345767
58643803101
56306300000
72582585379
52752750000
59659650000
59009000000
63243127303
70170150000
72172150000
...

result:

ok 

Test #118:

score: 35
Accepted
time: 121ms
memory: 18900kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
100000 1000 50000 1000 1000000
1880000000 1320000000 800000000 825000000 1910000000 470000000 1500000000 165000000 1020000000 835000000 1365000000 1095000000 45000000 2155000000 175000000 1605000000 270000000 945000000 550000000 2140000000 1325000000 860000000 625000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
7000000000
5389418159
7129626331
6094500822
7365912047
5479570751
5560000000
6734826599
6866392675
5470000000
7132376733
6410000000
5985000000
5635000000
5775085469
6965000000
6270000000
5389369682
5790000000
6560457464
7793241536
6665000000
6810498527
5548371251
...

result:

ok 

Test #119:

score: 35
Accepted
time: 129ms
memory: 18800kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1000000 1000 50000 1000 1000000
26776750000 9697187500 24211687500 18143125000 500500000 23523500000 23398375000 17329812500 31093562500 20395375000 4066562500 28153125000 14639625000 31031000000 28716187500 26213687500 14889875000 28841312500 2252250000 28591062500 ...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
64620110976
56006000000
74863717321
81281250000
58532248974
59634625000
66472233734
68051144753
67267250000
54942437500
53440937500
53378375000
63951437500
66870184820
64702187500
56631625000
90612531931
81217769539
53253250000
66516500000
72950118042
71646625000
...

result:

ok 

Test #120:

score: 35
Accepted
time: 121ms
memory: 18912kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
2000000 1000 50000 1000 1000000
19919900000 25225200000 25925900000 27527500000 10010000000 18018000000 18918900000 28728700000 38438400000 4104100000 16016000000 16116100000 41241200000 38038000000 24524500000 24124100000 36636600000 2502500000 3303300000 6606600000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
126926900000
143043000000
106157307995
157473551600
117717700000
120720700000
125681238786
119874558080
120834338476
112913969649
114714700000
140040000000
144845249727
111711700000
126826800000
109909900000
135535500000
111511500000
126526500000
106272489462
1326...

result:

ok 

Test #121:

score: 35
Accepted
time: 950ms
memory: 55796kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
1498 1000 1 1000 1000000
157684 486026 130738 170658 451595 465068 282933 254989 435128 71357 87824 476545 285927 144710 463072 493511 419659 92315 184630 359779 77844 172654 193612 156187 307883 73852 445108 185129 468062 297404 415667 124251 135728 207085 354290 40...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
452504
619226
430412
285754
533573
679636
523647
535856
814092
172163
223694
148974
672909
822791
393755
834656
455168
395434
549331
983824
626462
211173
833206
884499
184884
475414
206014
146589
607835
34966
877988
463328
860920
131375
8977
787025
911308
907046
2...

result:

ok 

Test #122:

score: 35
Accepted
time: 1332ms
memory: 55816kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
30455 1000 999957 1000 1000000
706000002 484000037 302000003 385000031 230000027 445000005 22000016 237000014 837000038 220000023 923000028 36000037 809000040 361000010 159000013 954000036 905000010 273000039 887000020 76000029 816000049 446000007 876000005 637000016...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
31417987582
30823077706
30864291298
30547442835
30762137136
31121766243
30542059959
31082391795
31037993188
30581117891
31000102201
30803738020
31119234429
30929666176
31318175272
31113026222
31144455251
30898164436
30880062409
30698529814
30993153026
31403392304
...

result:

ok 

Test #123:

score: 35
Accepted
time: 1360ms
memory: 56136kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
32743 1000 999945 1000 1000000
411000039 740000022 92000043 367000027 261000015 22000047 732000004 245000005 505000052 361000006 438000029 819000027 728000007 787000023 899000046 955000032 833000047 200000014 283000019 828000018 987000022 468000038 178000025 30300004...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
33057783498
32912104188
33702087816
32961924958
32920950929
33627109351
32801350098
32806668999
33255792097
33082739543
33112281400
32943273397
33012452373
33149564611
33523073915
33015731719
32805601635
32741527551
33393884481
33505333875
32972371416
33204030750
...

result:

ok 

Test #124:

score: 35
Accepted
time: 1328ms
memory: 55884kb

input:

XwWPuInrOjpekAwGKojzwKw3yVDtdkGS
35343 1000 999943 1000 1000000
720000029 705000004 439000060 521000000 206000023 244000038 924000017 834000009 803000025 602000045 911000042 490000006 501000029 98000031 724000011 817000009 199000005 836000017 222000048 968000006 362000040 514000045 466000014 5220000...

output:

mGlgT4yvr1qPbquFwkxRVh9hMn0Mrxoz
OK
36087180142
36127037315
35814014808
35559503943
35620411860
36277846541
35707716990
35898064807
36065190201
35673523138
36221503950
35644679168
36318669449
35358555918
36106267799
36256793734
36236014557
36211397158
36022311986
35855090437
36237959643
36110787246
...

result:

ok 

Extra Test:

score: 0
Extra Test Passed