QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#546256#7433. 梦想歌UrdAC ✓542ms82300kbC++172.3kb2024-09-03 21:42:072024-09-03 21:42:07

詳細信息

Test #1:

score: 100
Accepted
time: 0ms
memory: 26452kb

input:

1000 1000
789235149 971630276 32611109 914526454 322116555 603760422 515825265 152313854 448798679 318603927 286945416 136257807 504937778 335098720 99992633 383505822 680671658 103868338 645514353 842590958 30634297 935721702 280349478 690724214 918666175 189139505 674200041 396011000 363889197 296...

output:

600944721
649102944
725908539
243994087
589202294
759014306
788383814
260115709
926504062
9265023
962138031
612845865
773507352
285660823
814892763
408912789
939700909
957366550
484438754
127214516
403914890
373322009
22657345
939562528
881078720
867172188
356178355
542108952
490075331
381577999
377...

result:

ok 482 numbers

Test #2:

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

input:

1000 1000
534742000 984766932 272199542 309111581 215919561 297508370 391925746 729477672 992274627 534076312 327885429 744059797 401610545 851857326 834428137 751138612 653239459 973285764 50921781 663017859 242125898 813347640 323422967 885478786 314541246 189116029 410482851 616010211 174909574 2...

output:

970754963
992153693
759208888
651420397
267478413
734139
652720522
915279669
159132753
655638231
696174062
925635967
852035359
842012930
336761709
449199211
14410985
988308720
937081577
700432138
14440420
633703103
197806724
825574892
497230457
223310522
670374910
852035359
662384325
749214062
15913...

result:

ok 497 numbers

Test #3:

score: 0
Accepted
time: 7ms
memory: 30416kb

input:

1000 1000
815867921 529986771 643152391 966762063 606847695 982170079 951392018 703136810 278976515 163311576 93907559 628138550 866344034 256448043 188647645 131806199 317707168 385626401 509648932 635114399 888113354 863452860 214599564 307938888 648991902 842278122 736997 40688456 605102695 14679...

output:

732329632
276838273
537296966
108949144
416220214
699184440
835897731
885604048
765476847
941904426
804241724
377556169
489280116
621732639
918248492
751981729
433215581
988397263
964916665
462630882
485276175
820866551
987405316
313310473
895523355
355223591
555614571
949935262
189856982
864743143
...

result:

ok 488 numbers

Test #4:

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

input:

1000 1000
621258734 108867175 403374506 534873654 326399910 385424258 920139609 609610853 101960551 345662769 175540472 815107902 230359739 966868341 114326464 320052539 902415433 683231153 606634007 137661520 56441794 287884186 331294130 377143048 328308473 725954626 839759144 515393071 851673248 9...

output:

24341394
414812091
781190717
892203375
936154187
36117334
299461144
172721786
744026989
886717818
693078245
323995514
860169846
549594594
586803449
894856619
299173772
873534871
535321541
355801959
899711498
86741029
488948769
807646958
243860524
677244727
480207401
722384144
402177877
665426411
375...

result:

ok 492 numbers

Test #5:

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

input:

5 10
935481048 714297574 866605439 986833401 750779428
1 2 3 2
2 4 -261382702
2 1 -324056819
1 2
1 2
1 2
2 5 -252134746
2 2 -76970020
2 4 -237678796
2 4 18854351
1 4

output:

866605439
866605439
866605439
506626254

result:

ok 4 number(s): "866605439 866605439 866605439 506626254"

Test #6:

score: 0
Accepted
time: 541ms
memory: 81508kb

input:

200000 200000
338063221 831437218 237223404 214023052 122569681 974803678 652789176 565986713 400018329 17162272 36628853 989700233 805067261 477735383 450928654 348070660 493818889 735228121 828104895 497999694 242344610 10990524 291190106 488125577 881296213 707265653 339384641 648461900 113524198...

output:

902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
902404221
...

result:

ok 99854 numbers

Test #7:

score: 0
Accepted
time: 528ms
memory: 81732kb

input:

200000 200000
788093027 564316263 678451592 479583412 508388200 37067964 854743875 531973916 721661692 793865338 217605548 538570809 123714805 362521633 149929089 192422873 64176400 954693821 217555914 789477880 771709013 900755993 592710554 862116560 205479618 68063216 410435616 590191397 107775864...

output:

745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
745829979
...

result:

ok 100093 numbers

Test #8:

score: 0
Accepted
time: 537ms
memory: 81700kb

input:

200000 200000
535895289 424979905 929936698 358253695 651982640 279279896 196623028 658962063 630680080 725057708 476324427 902610693 541787465 577156295 13981538 348336689 909695963 231524315 453466655 677312391 490998109 276951362 522975904 177550167 904905607 607772384 539127225 771624444 9762252...

output:

880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
880787574
...

result:

ok 99986 numbers

Test #9:

score: 0
Accepted
time: 542ms
memory: 81704kb

input:

200000 200000
951118474 62731288 704083236 503953392 444643890 405106702 808596601 784554622 744558296 767666462 312778401 243363799 355656363 932038007 841580313 954692664 227020482 101162750 703546271 680858794 556029683 200607826 802102062 496310175 579150337 903801592 148430234 395832376 9764975...

output:

668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
668704413
...

result:

ok 99734 numbers

Test #10:

score: 0
Accepted
time: 527ms
memory: 82300kb

input:

200000 200000
132443494 672375898 738227033 500863851 776561028 436544305 596934403 737826953 945497091 628931875 319665426 902549405 130277194 169712725 897885066 858399058 735577682 868077068 131440219 954636197 668157630 607046319 392705987 110398447 591049478 680876679 711165660 285695482 569233...

output:

617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
617585990
...

result:

ok 100174 numbers

Test #11:

score: 0
Accepted
time: 204ms
memory: 69728kb

input:

199999 200000
703514671 316528510 498595650 250631093 838816278 495519393 500452796 267280489 408004644 123835288 218455032 504945200 55091723 486634528 845536232 559235365 753171722 527447355 769213308 696339788 146018443 856810484 596012446 255753519 122656827 522153915 344874858 692989738 5227099...

output:

954966937
792326637
779974015
868713423
836974036
927844242
438320888
995756674
572756921
971203735
954966937
792326637
929562276
792326637
438320888
571957941
971203735
822623272
740782557
995756674
995756674
792326637
792326637
568106434
737825351
977203293
839984917
652471741
812550783
775997183
...

result:

ok 99896 numbers

Test #12:

score: 0
Accepted
time: 208ms
memory: 69944kb

input:

199999 200000
883082860 725173470 73865019 633014762 874352820 37745282 171961009 620623918 250809158 675702455 953923638 931050337 103883817 74828581 568307514 202986493 474927984 745159214 394589060 36356858 774461661 649781671 68887510 961803181 588806834 738363639 902708213 350355924 873195576 5...

output:

618967505
838688871
909310126
560000390
618967505
803366219
820405725
692068070
760185772
632937241
951793443
851117572
761287769
990890875
841005282
735553730
761287769
749234806
761287769
921352621
618967505
865195195
865195195
894335143
761287769
919105816
595596160
761287769
741040244
735745206
...

result:

ok 99596 numbers

Test #13:

score: 0
Accepted
time: 208ms
memory: 68716kb

input:

199999 200000
893273639 704668866 422404709 422157167 846944330 843107745 395790599 607626961 145768069 187597825 251810501 600863332 758601982 207356074 366241791 410341629 437888808 303265113 764707934 410979798 384169291 681816678 931872768 490478930 66343281 438464593 477409363 479830034 7304963...

output:

712810456
966646387
882788439
978749522
913010379
567434077
966646387
992696335
996489339
831026720
880548106
913010379
831026720
913249949
882788439
978749522
683439912
978749522
913010379
913010379
946463930
440403780
567434077
741842940
913010379
886352527
978749522
813515740
913249949
927619548
...

result:

ok 99683 numbers

Test #14:

score: 0
Accepted
time: 202ms
memory: 70024kb

input:

199999 200000
809603474 230968414 388525718 139280734 662470451 649445984 412565887 896590004 355912697 566600414 216248729 154177592 301591648 749243199 307248505 708000120 564207302 208180595 489373865 767110292 691442291 766755068 577222381 453503223 780397113 865955926 93456548 38014502 50637687...

output:

786863762
994939327
870265802
816636585
971839199
914577710
971839199
819905610
580717980
816636585
732947551
649673311
971839199
828516451
886300487
982939253
988413105
706594258
879883085
816636585
988926981
536193502
849876731
963284279
971839199
782485188
971839199
731698698
896212540
929037199
...

result:

ok 100039 numbers

Test #15:

score: 0
Accepted
time: 217ms
memory: 70112kb

input:

199999 200000
551828930 145750136 592907562 173966909 293913753 113325402 370342836 82286 6997808 534091596 869165926 709266655 376442958 268107546 300890126 297858008 456477517 455393958 644768207 794419714 234287260 914477915 713858684 116530791 601060122 695557234 973763730 234746996 403896323 42...

output:

821721897
923142125
908663265
856484267
843497486
643152242
943427824
827490642
657370798
857377990
776522293
821721897
953220776
881841701
986536718
934775746
935637337
953220776
996305256
953220776
964661478
873603255
853616731
776522293
778706752
583239136
989487600
953220776
843497486
776522293
...

result:

ok 100031 numbers

Test #16:

score: 0
Accepted
time: 127ms
memory: 71472kb

input:

200000 200000
543174879 346332658 886888992 502566271 374402336 231489079 496780315 620336821 397802986 358900407 237001879 938973306 335897390 199667225 825217241 696884973 798827605 763816746 683537649 803323066 378600845 452624330 725202189 650634294 352503902 814478535 95686471 43351167 36271556...

output:

755413097
582089059
915343160
164257714
337197575
738125380
337197575
979097574
970688575
886982120
910229283
995721695
860559623
980104621
337197575
337197575
734423029
886982120
915343160
871460262
502695508
337197575
915343160
227634036
734423029
869465702
970688575
28136034
915343160
444244397
1...

result:

ok 100116 numbers

Test #17:

score: 0
Accepted
time: 137ms
memory: 70524kb

input:

200000 200000
818048106 997983414 555982152 66727334 264217368 392660579 497562491 455553450 114011206 41222825 745195606 414180788 991210899 151814975 412750007 281412028 360137232 53474830 392917211 794182644 943390855 456196784 944387687 304694569 231970081 994047174 63797725 731134643 36773582 1...

output:

644314877
984405660
997473412
881789012
817680275
967957174
989419086
988587802
599319747
943390855
601216169
930956758
965671923
997473412
819400719
912253761
601216169
870073959
720865140
229615907
78967554
989419086
908447359
967957174
989419086
755973805
720865140
965671923
180263180
78967554
46...

result:

ok 100198 numbers

Test #18:

score: 0
Accepted
time: 140ms
memory: 70480kb

input:

200000 200000
74343519 165894283 487943478 559898037 906801969 560160445 761069673 166680049 991863010 553508626 99802616 868527675 705426527 403315075 842158039 865326211 218850346 115693383 15284272 959392126 352823665 222391832 934038380 118437576 993953195 16870252 464135935 566086831 752366189 ...

output:

900873031
308272186
246047986
532262651
838969951
436949474
118344124
715092432
920447410
831357855
886631704
995742616
379429312
436949474
212591673
880870138
436949474
880870138
969383470
451339153
900873031
959392126
916849087
212591673
573060516
436949474
745632858
838969951
959302047
727572296
...

result:

ok 99971 numbers

Test #19:

score: 0
Accepted
time: 137ms
memory: 69944kb

input:

200000 200000
854692936 406678458 317887131 772782283 296547586 878989025 335662457 996803209 77349681 182106473 994656549 821847608 595151391 457139078 116175909 42715085 596213032 280950473 259559302 694931751 224490375 260083827 437304085 20958923 813621485 170412220 221185101 543721528 722741358...

output:

809880406
944139711
576044697
532579227
569001713
629220216
925065488
708345726
708345726
583186360
779182133
532579227
165915288
117301225
925065488
919327737
532579227
117301225
648464011
190540046
258977593
575278941
190540046
283909311
629903716
470742230
575278941
646367821
258977593
708345726
...

result:

ok 99674 numbers

Test #20:

score: 0
Accepted
time: 118ms
memory: 69588kb

input:

200000 200000
876999277 533809816 240396516 101504099 717792961 755570492 368386973 54670047 61611596 720885865 555528883 234558034 514314472 797661418 341304293 113398811 628343674 457920867 69748645 533696046 533589967 720568140 266534103 504471027 765028371 208549723 4732 632453545 961544961 2801...

output:

450112740
126143995
959609823
628343674
726293663
247981755
504471027
150148563
916789832
943136351
797661418
726293663
915384594
845191388
797661418
332047792
726293663
887570154
844218790
844218790
959609823
733944289
655294621
720885865
934639194
908668615
959609823
337081647
844218790
504471027
...

result:

ok 99914 numbers

Test #21:

score: 0
Accepted
time: 131ms
memory: 54236kb

input:

131072 200000
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 9...

output:

100000131072
131008
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
131008
100000131072
131008
100000131072
131008
10000...

result:

ok 100000 numbers

Test #22:

score: 0
Accepted
time: 128ms
memory: 55840kb

input:

131072 200000
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 9...

output:

100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
131008
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
98240
100000...

result:

ok 100000 numbers

Test #23:

score: 0
Accepted
time: 131ms
memory: 56256kb

input:

131072 200000
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 9...

output:

100000131072
131008
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
131008
10000...

result:

ok 100000 numbers

Test #24:

score: 0
Accepted
time: 132ms
memory: 53708kb

input:

131072 200000
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 9...

output:

100000131072
98240
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
98240
100000131072
131008
100000131072
98240
1000001...

result:

ok 100000 numbers

Test #25:

score: 0
Accepted
time: 129ms
memory: 55532kb

input:

131072 200000
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 9...

output:

100000131072
98240
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
131008
100000131072
131008
100000131072
98240
100000131072
131008
100000131072
98240
100000...

result:

ok 100000 numbers

Test #26:

score: 0
Accepted
time: 254ms
memory: 72780kb

input:

200000 200000
50000 100000 150000 200000 250000 300000 350000 400000 450000 500000 550000 600000 650000 700000 750000 800000 850000 900000 950000 1000000 1050000 1100000 1150000 1200000 1250000 1300000 1350000 1400000 1450000 1500000 1550000 1600000 1650000 1700000 1750000 1800000 1850000 1900000 19...

output:

1000000001050000
10000000000
1000000001050000
10000000000
1000000001050000
10000000000
1000000001050000
10000000000
1000000001050000
10000000000
1000000001050000
10000000000
1000000001050000
10000000000
1000000001050000
10000000000
1000000001050000
10000000000
1000000001050000
10000000000
1000000001...

result:

ok 100000 numbers