QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#510590#5203. Easy AssemblyGuanYunchangAC ✓3ms4280kbC++201.1kb2024-08-09 09:29:502024-08-09 09:29:50

Details

Tip: Click on the bar to expand more detailed information

Test #1:

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

input:

2
3 3 5 8
2 9 2

output:

1 2

result:

ok 2 number(s): "1 2"

Test #2:

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

input:

1
1 1

output:

0 0

result:

ok 2 number(s): "0 0"

Test #3:

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

input:

1
1 1000000000

output:

0 0

result:

ok 2 number(s): "0 0"

Test #4:

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

input:

1
2 1 2

output:

0 0

result:

ok 2 number(s): "0 0"

Test #5:

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

input:

1
2 1 3

output:

0 0

result:

ok 2 number(s): "0 0"

Test #6:

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

input:

1
2 2 3

output:

0 0

result:

ok 2 number(s): "0 0"

Test #7:

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

input:

1
2 2 1

output:

1 1

result:

ok 2 number(s): "1 1"

Test #8:

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

input:

1
2 3 1

output:

1 1

result:

ok 2 number(s): "1 1"

Test #9:

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

input:

1
2 1 1000000000

output:

0 0

result:

ok 2 number(s): "0 0"

Test #10:

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

input:

1
2 1000000000 1

output:

1 1

result:

ok 2 number(s): "1 1"

Test #11:

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

input:

1
10 469824905 571701214 23624320 688416005 50705647 146779011 168882039 274124876 425787403 398650749

output:

5 5

result:

ok 2 number(s): "5 5"

Test #12:

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

input:

1
10 531024457 257806065 278607414 751547170 817188083 606910175 154942408 982356354 910281308 835317020

output:

7 7

result:

ok 2 number(s): "7 7"

Test #13:

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

input:

1
10 294221243 787120441 70147219 86087312 141707343 65274729 331433884 57927999 757193855 238508732

output:

7 7

result:

ok 2 number(s): "7 7"

Test #14:

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

input:

1
10 296094740 321802219 395888174 421441577 499796309 715358733 571294031 588654238 533108023 838379396

output:

4 4

result:

ok 2 number(s): "4 4"

Test #15:

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

input:

1
10 194995703 265687483 338341045 351754262 594721649 713360816 724966087 870514471 898620495 937808514

output:

0 0

result:

ok 2 number(s): "0 0"

Test #16:

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

input:

3
1 812438872
6 855149742 163256253 512853819 552937068 533111598 923969831
3 204069398 503558734 767208237

output:

6 8

result:

ok 2 number(s): "6 8"

Test #17:

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

input:

3
2 610337807 201074256
6 259850393 767293344 857023239 123375085 366411383 82079941
2 808837557 809497938

output:

6 8

result:

ok 2 number(s): "6 8"

Test #18:

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

input:

3
3 143377699 159234952 882365813
5 840921162 682929709 639889771 872637068 892028426
2 928992487 362658061

output:

6 8

result:

ok 2 number(s): "6 8"

Test #19:

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

input:

3
3 874510565 943287381 748145857
2 176514643 29266828
5 224846012 423857613 972709267 788568148 870490817

output:

4 6

result:

ok 2 number(s): "4 6"

Test #20:

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

input:

3
1 39142627
8 97415845 144903987 153963000 191732016 262883582 340757081 482907987 547253386
1 795158002

output:

0 2

result:

ok 2 number(s): "0 2"

Test #21:

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

input:

10
1 899372691
1 108662578
1 666339057
1 783016766
1 110465612
1 863100781
1 119285409
1 31783198
1 623300126
1 7350117

output:

0 9

result:

ok 2 number(s): "0 9"

Test #22:

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

input:

1
100 101889828 200465232 605396437 441106608 666362820 803544500 681998506 206569825 244087392 139795020 135175462 662986235 955459207 560848612 339903822 350828252 631799875 920456235 405502976 790670672 899963408 956680866 616486091 842582779 58062392 401698084 131588536 258534259 138934521 62179...

output:

98 98

result:

ok 2 number(s): "98 98"

Test #23:

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

input:

1
100 3942935 17657396 27442012 203150029 670123296 154245005 88939965 89807634 109058710 104175218 143512921 140031401 720362607 147051325 514485211 967804027 154123266 63176388 183787689 199638805 53637067 214286432 577651046 402722937 228601087 246009536 635339883 247338695 256115907 259721033 26...

output:

82 82

result:

ok 2 number(s): "82 82"

Test #24:

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

input:

1
100 6618601 33721089 33845717 41875316 65714268 75804913 79088155 85059946 96305188 96377132 100824364 102357758 112038928 122709396 130329354 135559650 137372857 182794756 185443531 191247448 223520304 224258974 239628038 267846496 284183378 287776097 310146411 322255496 329217558 334518837 34730...

output:

0 0

result:

ok 2 number(s): "0 0"

Test #25:

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

input:

5
24 962396800 686052139 384484759 966532569 173319933 641945713 948687700 161319046 596514702 234754277 260129958 639673263 419561816 561778230 835772696 969337864 571088645 812688556 322939847 45052045 789340142 762144794 411699345 544228533
11 914005965 383153151 6404662 948083792 921592391 78942...

output:

93 97

result:

ok 2 number(s): "93 97"

Test #26:

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

input:

5
32 3645230 319476315 561066454 277746355 640689286 57966254 340981833 478560413 412746236 827856379 119750135 710522123 86908483 145542881 153621068 364769664 869306957 194462955 710522919 216155113 339546045 250485861 122167463 264092516 264280918 265920593 266889714 269840942 744848068 646631122...

output:

86 90

result:

ok 2 number(s): "86 90"

Test #27:

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

input:

5
58 140884015 140995277 151512259 157267698 166885544 169497876 183820250 185187140 201462032 204956239 221361026 221775396 222945068 222969803 226516087 229487097 234206791 240076991 250767850 253905880 258835871 260874416 264776379 268620280 272061609 311355280 329596664 335053496 368002281 39485...

output:

0 4

result:

ok 2 number(s): "0 4"

Test #28:

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

input:

100
1 541545252
1 774017554
1 80792646
1 711963901
1 819307252
1 703611443
1 792890085
1 95340901
1 424846114
1 722031961
1 972138860
1 152058243
1 490903423
1 84564442
1 760254333
1 113542094
1 753968832
1 940018549
1 151244561
1 797906972
1 868794372
1 538400778
1 216020796
1 287421766
1 626836922...

output:

0 99

result:

ok 2 number(s): "0 99"

Test #29:

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

input:

1
1000 465162029 65092357 227278101 314509027 10280018 202474705 873686845 486237343 144429410 383581525 629824297 301144379 734683168 166533406 385491957 273231450 828748410 981379422 82222715 460253893 602457150 219338504 683117326 485801425 877469559 61137665 137317885 502962308 56922190 77031835...

output:

999 999

result:

ok 2 number(s): "999 999"

Test #30:

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

input:

1
1000 848820927 5824355 6122173 224233925 600795310 7106432 8389886 41911989 719667707 84876185 13599723 13772052 14598644 16602357 773226663 19096474 20214368 20313602 641709883 23289798 358005979 250434987 67064787 124759777 857825677 27025771 29770548 923075994 276147764 33870503 38227678 267795...

output:

878 878

result:

ok 2 number(s): "878 878"

Test #31:

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

input:

1
1000 2415374 4048895 5155468 5584322 6318581 8128095 8765823 9785127 10580301 14481221 15329090 15759763 16096243 20199074 21235517 21368939 21653422 22318559 22615504 23322561 24676312 24968336 26011817 26597308 26766874 27197875 27331050 27437995 27801677 29286457 31514021 31596242 33400847 3413...

output:

0 0

result:

ok 2 number(s): "0 0"

Test #32:

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

input:

2
163 432299662 322367385 472665356 81577105 22006700 661266017 794295841 67460633 550671119 878962208 451391546 953274086 169550867 53457482 210141818 576867176 153854826 513492311 922766822 701308289 799835349 339502776 26054134 435600018 865092772 879563181 855122151 460246455 43442625 206576462 ...

output:

997 998

result:

ok 2 number(s): "997 998"

Test #33:

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

input:

2
684 215125173 225578312 727473890 736363694 7785549 10539806 143377749 495306909 13066437 14451226 15070380 16046493 16365584 438741850 18358202 729341085 895243372 309265031 105524470 273720565 23190132 23246504 626128108 24116149 663578301 92219838 25858157 49405248 29107955 797906199 881405525 ...

output:

888 889

result:

ok 2 number(s): "888 889"

Test #34:

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

input:

2
827 171732086 172163639 172675870 175020043 175894044 176188691 176300531 176402185 176951323 177255448 178720015 178977476 180036486 180274276 180646371 182484000 182934615 183387129 184052999 184348857 184367098 184950697 184987171 187539844 187806699 187963233 188475944 190900448 191863718 1932...

output:

0 1

result:

ok 2 number(s): "0 1"

Test #35:

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

input:

100
16 324422452 801122409 521533943 597003199 259474026 127996356 922799133 162555137 747748023 331141869 511904249 64409321 841681511 633039879 31194994 430541007
3 621665022 635709984 520500419
4 753881475 599791124 906840359 146579131
37 664238982 594248632 65964335 46275260 913274165 745070382 ...

output:

899 998

result:

ok 2 number(s): "899 998"

Test #36:

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

input:

100
7 40452378 40871490 613033528 444709789 43037258 453101515 43366940
12 454399693 949035317 758854666 847905708 662909629 839498727 670908664 900866512 631651808 952146956 833032962 114038891
29 393633662 691245858 971794069 690282718 245806254 231515202 992891450 906305295 753987233 907145558 61...

output:

798 897

result:

ok 2 number(s): "798 897"

Test #37:

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

input:

100
15 4215364 4336832 5073468 5076212 5471510 6452087 6601760 7465745 8508944 10283313 10782900 10856674 11673099 12848807 14228307
30 623633883 623777846 624482013 627201091 627606849 631508696 632648398 633461751 633976355 634714617 635394694 636654258 639713605 641797039 642469437 642780271 6433...

output:

0 99

result:

ok 2 number(s): "0 99"

Test #38:

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

input:

1000
1 221599348
1 490117036
1 969928060
1 509896224
1 260328065
1 483425112
1 808485876
1 350020018
1 114348131
1 236998096
1 645710911
1 845186494
1 223357901
1 691612615
1 628535677
1 699629172
1 793053363
1 766313436
1 578043801
1 349148205
1 698947895
1 55021799
1 70492715
1 387596948
1 5374281...

output:

0 999

result:

ok 2 number(s): "0 999"

Test #39:

score: 0
Accepted
time: 2ms
memory: 3744kb

input:

1
10000 984708277 743196626 437845277 315176291 112783745 18909897 652895708 827116922 249274400 488259574 397517337 877676893 901810029 634887676 909291408 172692007 964643285 745857185 321381212 373047554 570484022 18618533 886001513 982233051 986761014 935036226 623090299 821997613 383655042 4734...

output:

9998 9998

result:

ok 2 number(s): "9998 9998"

Test #40:

score: 0
Accepted
time: 2ms
memory: 3688kb

input:

1
10000 294345054 848697967 935592193 418425053 134390810 636220 678611988 797755141 240935708 46885036 566625044 391596785 1565331 800191064 1967299 483438268 821506826 631296408 323765776 864391458 784977576 677404497 2836195 2849041 976897130 902443573 476589324 425701355 692141182 89832009 33502...

output:

9852 9852

result:

ok 2 number(s): "9852 9852"

Test #41:

score: 0
Accepted
time: 2ms
memory: 3668kb

input:

1
10000 78511 82236 111249 111682 755082821 978675481 549821 769605 671629394 913085611 296146454 1007314 1027162 331394624 1171391 288747590 907352808 1528085 763996925 735826530 1774110 791462980 541873409 2048689 2136429 15398342 773183683 930604162 2517460 2571815 457306503 918253305 2753870 244...

output:

8749 8749

result:

ok 2 number(s): "8749 8749"

Test #42:

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

input:

1
10000 38973 332605862 170440 340901 405143 674963669 612953 617226 306938157 918940 1217093 1275483 400549041 1484646 1602443 286034383 276551939 1855069 2004988 565088201 2144669 2179310 2347562 2394625 2417831 2496880 2552036 2557302 3162653 745134326 3291935 3400388 3565439 3636924 3641683 3777...

output:

6786 6786

result:

ok 2 number(s): "6786 6786"

Test #43:

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

input:

1
10000 75386 123409 309130 348805 380111 493170 601246 607151 670770 749297 769810 894885 914891 1328649 1415639 1618078 1760568 1781719 1876461 2062879 2191341 2391199 2432440 2497502 2575716 2619057 2816230 2841217 2850047 2939170 3071091 3136701 3241773 3566019 3637486 3727215 3742744 3866626 38...

output:

0 0

result:

ok 2 number(s): "0 0"

Test #44:

score: 0
Accepted
time: 2ms
memory: 3732kb

input:

2
7265 812624643 302286877 757872241 435786436 374042986 737221510 568274336 713321521 369519702 967577004 365144919 154188608 185742803 889040085 79011826 898542267 605747781 913194377 332840872 900401009 661382319 803244742 171429771 127749703 553582204 681535588 84026049 623245539 270052733 34160...

output:

9998 9999

result:

ok 2 number(s): "9998 9999"

Test #45:

score: 0
Accepted
time: 2ms
memory: 3700kb

input:

2
1953 844784807 406618450 250598906 435685 591361 748063591 849490 888447435 703342427 40856013 453955036 755755063 189428123 936504277 397629862 916449310 630336160 900128381 724019301 946885596 887561370 2505218 2551120 2595397 463097975 2909220 987958901 366761930 636721505 772368845 353269324 3...

output:

9841 9842

result:

ok 2 number(s): "9841 9842"

Test #46:

score: 0
Accepted
time: 2ms
memory: 3680kb

input:

2
5492 455796506 587138446 353207267 819865554 429490755 456462548 456536459 719958885 242296940 156815187 610766905 457469889 937410065 457580602 349489087 678270507 110829544 457754903 87952691 869620370 449123636 177205712 458455201 853779279 546532084 755222190 27816797 562193559 459621426 72264...

output:

8760 8761

result:

ok 2 number(s): "8760 8761"

Test #47:

score: 0
Accepted
time: 2ms
memory: 3672kb

input:

2
3739 625279930 779584829 625322531 846088561 625709201 979887925 773198478 568550378 814226273 83083403 626318516 626338919 479951924 626377882 626474025 475156942 39933517 944144468 627023736 616851000 627357215 627465639 702705272 627491767 757821645 514391422 627814146 627924988 628008364 73007...

output:

6944 6945

result:

ok 2 number(s): "6944 6945"

Test #48:

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

input:

2
3543 13097 155677 514004 549682 562802 571767 666036 683386 766273 894347 1051549 1063444 1182013 1411864 1799708 1856606 2148506 2229516 2454385 2490529 2529728 2599030 2665666 2741989 2948572 2961487 2963711 3128663 3212759 3318043 3665398 3732916 3740574 3755487 4108971 4111069 4196521 4231951 ...

output:

0 1

result:

ok 2 number(s): "0 1"

Test #49:

score: 0
Accepted
time: 2ms
memory: 3688kb

input:

100
43 219713052 769202179 748400411 164599202 22891121 783761324 370280645 894623716 947148868 816703937 228405482 886260146 855688138 194834839 18785046 771367034 766056940 535858869 689856984 891696131 474679645 177023558 33973181 601390908 9621344 635679447 29054713 603577030 493926790 996293944...

output:

9899 9998

result:

ok 2 number(s): "9899 9998"

Test #50:

score: 0
Accepted
time: 2ms
memory: 3720kb

input:

100
55 114194475 191709059 551356326 298981333 395497196 732850236 704623999 436036139 226298450 552033392 189780408 804294678 391113081 217167065 255516516 845388379 872769672 592279986 14401626 552886519 552965422 671874984 301192601 878894178 553254897 55628509 922854899 362832495 174407504 94924...

output:

9741 9840

result:

ok 2 number(s): "9741 9840"

Test #51:

score: 0
Accepted
time: 2ms
memory: 3732kb

input:

100
98 20295634 664556240 821395587 394211186 97651978 20601272 219152496 20520512 338115110 333138565 567957714 587284780 21420630 959010769 22008263 408335555 184776485 22200994 22357598 653344941 22647806 66654312 395801160 22944476 23089704 938499926 23209289 958346468 32475042 23796981 97685434...

output:

8687 8786

result:

ok 2 number(s): "8687 8786"

Test #52:

score: 0
Accepted
time: 2ms
memory: 3736kb

input:

100
68 360035373 876921232 360522248 148910560 360566356 360656969 360678697 480100191 744742972 361307136 361429477 553750119 361440756 218194203 227079346 361702942 438380597 361891972 361898328 361900018 362170409 629408067 362262005 362329933 238826519 565999687 362599000 362651693 362931360 363...

output:

6765 6864

result:

ok 2 number(s): "6765 6864"

Test #53:

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

input:

100
122 752077900 752169579 752210688 752255171 752266727 752269534 752329287 752347254 752513218 752668332 752768801 752842245 752842862 752888033 752938492 752963370 752965883 753241592 753486380 753597197 753625957 753642564 753773782 753781245 753799430 753882671 753953639 754055808 754138197 75...

output:

0 99

result:

ok 2 number(s): "0 99"

Test #54:

score: 0
Accepted
time: 2ms
memory: 3752kb

input:

1000
11 422457488 772593079 900961359 611875115 95547968 283170091 296349136 966119385 779357330 624264611 728397956
16 407431409 436626575 640944311 19662508 374010126 491431822 208408309 657041764 379758812 638954112 902253693 11755231 591400559 62012230 910708219 243836665
20 671443441 642677758 ...

output:

8999 9998

result:

ok 2 number(s): "8999 9998"

Test #55:

score: 0
Accepted
time: 2ms
memory: 3720kb

input:

1000
1 786753533
1 398266447
9 171887609 293105017 480824347 725927946 385446108 788064675 594681238 610517663 441708591
14 444241332 576916908 510759381 566872621 200840672 569949919 968878430 61692434 804844876 723436963 688722420 662798346 150955060 12659137
26 48148993 589629475 241707159 631797...

output:

8861 9860

result:

ok 2 number(s): "8861 9860"

Test #56:

score: 0
Accepted
time: 2ms
memory: 3720kb

input:

1000
14 985315018 125885260 441041830 548851618 615504240 230535179 404484961 343446693 887012814 704865677 837879818 355947712 887935101 887935318
13 547277303 682613336 975241037 704177327 945958568 604439179 242685390 805905355 716252439 742798223 704834429 840373944 358096902
2 336264426 2254994...

output:

7837 8836

result:

ok 2 number(s): "7837 8836"

Test #57:

score: 0
Accepted
time: 2ms
memory: 3720kb

input:

1000
5 149001037 149180328 149297826 149322715 149403914
6 167626681 167769833 628525313 402512764 168021258 168201284
6 478858500 919596479 856865454 208624491 698886587 894812980
4 264407072 518592228 299361989 217262469
2 532075787 532457592
14 755957973 727811296 630467544 784975573 909203060 63...

output:

6195 7194

result:

ok 2 number(s): "6195 7194"

Test #58:

score: 0
Accepted
time: 2ms
memory: 3752kb

input:

1000
3 228409243 228507338 228638989
24 497193735 497225187 497239066 497389142 497438750 497500760 497589009 497617087 497761441 497895899 497931147 497967796 498373404 498384368 498499033 498652898 498894699 498919732 499157778 499238674 499245386 499297778 499349342 499426927
1 867776733
16 12209...

output:

0 999

result:

ok 2 number(s): "0 999"

Test #59:

score: 0
Accepted
time: 3ms
memory: 4280kb

input:

9999
1 241737826
1 10528996
1 486569738
1 930289553
1 381528842
1 428985814
1 995273846
1 891217528
1 819761721
1 900324081
1 518037017
1 653805191
1 808426533
1 570253008
1 822378973
1 299583346
1 653380642
1 29846594
1 19598741
1 745142038
1 902057607
1 601136841
1 502491724
1 221806823
1 89774405...

output:

1 9999

result:

ok 2 number(s): "1 9999"

Test #60:

score: 0
Accepted
time: 2ms
memory: 4280kb

input:

9999
1 517964556
1 798561823
1 812809399
1 882690584
1 648958560
1 28014121
1 690729918
1 767939802
1 693889991
1 742899200
1 184581313
1 444793922
1 335041570
1 873522132
1 167694667
1 913869785
1 588321496
1 369918676
1 96855940
1 797833062
1 464863978
1 666912491
1 724387611
1 335887943
1 9109801...

output:

0 9998

result:

ok 2 number(s): "0 9998"

Test #61:

score: 0
Accepted
time: 2ms
memory: 4156kb

input:

10000
1 535389194
1 733882859
1 478028527
1 643484616
1 428368962
1 313957886
1 128377872
1 496024182
1 676254179
1 855702592
1 438467784
1 207622355
1 380190963
1 292961111
1 186007084
1 720714230
1 43139035
1 578030764
1 184312722
1 596656985
1 350969998
1 879793166
1 148941689
1 568816243
1 86980...

output:

0 9999

result:

ok 2 number(s): "0 9999"