QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#861699#9975. Hitoshizukuucup-team121#AC ✓140ms21300kbC++231.4kb2025-01-18 19:19:342025-01-18 19:20:02

詳細信息

Test #1:

score: 100
Accepted
time: 1ms
memory: 3712kb

input:

2
2
1 2
2 2
2 3
3 5
4 4
4 5
1
1 1
1 1000000000
1000000000 1000000000

output:

Yes
2 3 1
4 6 5
No

result:

ok >_< (2 test cases)

Test #2:

score: 0
Accepted
time: 59ms
memory: 3584kb

input:

100000
1
164154503 167959139
178382610 336470888
12298535 642802746
1
165064830 773386884
353585658 396628655
792066242 971207868
1
1607946 2087506
21674839 46761498
9518201 16843338
1
262361007 691952768
190585553 787375312
637191526 693319712
1
41970708 45277106
197619816 762263554
308360206 40724...

output:

No
No
No
Yes
3 2 1
No
Yes
1 3 2
No
No
No
No
No
Yes
1 3 2
Yes
2 3 1
No
No
No
No
Yes
3 1 2
No
Yes
3 1 2
No
No
Yes
3 1 2
No
No
Yes
1 2 3
No
No
No
No
No
No
No
Yes
2 1 3
No
No
Yes
2 1 3
No
No
No
No
No
No
No
No
No
No
No
No
Yes
2 1 3
No
No
Yes
3 1 2
Yes
2 1 3
No
No
Yes
1 3 2
No
No
No
Yes
2 3 1
Yes
2 1 3
No...

result:

ok >_< (100000 test cases)

Test #3:

score: 0
Accepted
time: 56ms
memory: 3712kb

input:

50000
2
36364670 641009859
15071436 75475634
20446080 476927808
357784519 503158867
206641725 322595515
268011721 645468307
2
247717926 939887597
808609669 973764525
496738491 710156469
463547010 860350786
757388873 784695957
29903136 208427221
2
26681139 67590963
458238185 475357775
80127817 135993...

output:

No
No
No
No
No
No
No
No
No
No
No
No
Yes
4 6 5
3 1 2
No
No
No
No
No
No
No
No
No
No
No
No
No
No
No
No
Yes
6 1 2
4 3 5
No
No
No
No
No
No
No
Yes
6 2 3
5 4 1
No
No
No
No
No
Yes
2 1 4
3 5 6
Yes
6 3 2
4 5 1
No
No
No
Yes
4 2 3
1 6 5
No
No
Yes
5 3 6
2 4 1
Yes
5 6 2
4 3 1
Yes
5 3 2
4 1 6
No
Yes
6 3 4
2 1 5
No...

result:

ok >_< (50000 test cases)

Test #4:

score: 0
Accepted
time: 60ms
memory: 3584kb

input:

33333
3
405068225 524125987
162463453 374288891
493199993 751244358
111234434 232930851
71448581 543529670
158749276 319728747
238956600 582720391
320275833 490702144
111160223 138628383
3
23006185 733781508
636477523 931759705
585852932 723534730
388969099 794937524
153929016 188451996
7487968 1448...

output:

No
No
No
No
No
No
No
No
No
No
No
No
No
No
No
No
No
No
No
No
Yes
7 1 9
8 3 6
2 5 4
No
No
Yes
1 8 6
7 5 2
3 9 4
No
No
No
Yes
7 9 5
4 2 1
8 3 6
Yes
7 5 3
4 9 2
6 8 1
No
Yes
4 6 2
9 3 5
1 7 8
Yes
9 1 8
6 3 2
5 4 7
No
No
No
Yes
8 2 5
9 4 1
3 6 7
No
No
No
Yes
6 4 9
2 1 3
8 7 5
No
Yes
5 6 4
9 8 3
7 1 2
No
...

result:

ok >_< (33333 test cases)

Test #5:

score: 0
Accepted
time: 61ms
memory: 3584kb

input:

25000
4
387784488 702209411
329025563 673102149
394641352 730593611
244761087 812959730
198875143 469496529
425799311 699021890
715498963 815487777
765027712 857896659
160339866 421876106
477145912 902179526
264824816 783856158
26239891 238642240
4
588094643 962475573
90297216 196513513
234289482 33...

output:

Yes
9 5 12
6 1 2
11 4 3
8 10 7
No
No
No
No
No
No
No
Yes
9 8 2
6 12 1
3 10 7
5 4 11
No
No
Yes
11 4 3
10 5 12
1 9 2
6 8 7
Yes
1 9 10
6 4 3
12 7 8
2 5 11
No
No
No
Yes
2 12 9
6 7 5
8 1 10
11 3 4
No
No
No
No
No
Yes
9 5 10
7 4 1
3 8 6
11 12 2
No
Yes
3 9 6
7 2 12
4 11 1
10 5 8
No
No
No
Yes
12 2 9
4 5 7
6 1...

result:

ok >_< (25000 test cases)

Test #6:

score: 0
Accepted
time: 60ms
memory: 3584kb

input:

20000
5
255424772 585325539
298257969 412106895
366545795 564718673
426199147 837699009
609084202 690430685
367932561 373282330
488491851 753287868
18693151 79866982
629564684 850348020
7594098 480642952
376090136 930919906
592321264 903492853
345689007 984789430
895853014 909607734
122083425 211655...

output:

No
Yes
7 15 3
5 11 8
13 9 4
14 1 2
12 10 6
Yes
3 4 12
11 1 5
8 2 6
15 14 7
9 13 10
No
Yes
15 2 11
9 6 7
8 12 3
14 10 13
5 4 1
No
No
No
No
Yes
2 5 6
1 4 14
11 15 9
13 8 10
7 3 12
No
No
Yes
4 3 8
1 15 6
12 11 7
13 5 10
2 9 14
Yes
10 11 14
13 15 1
9 12 3
4 5 2
6 7 8
Yes
6 8 5
7 11 9
14 10 2
12 15 13
1 ...

result:

ok >_< (20000 test cases)

Test #7:

score: 0
Accepted
time: 63ms
memory: 3712kb

input:

16666
6
26845100 58376259
4489038 5887448
307580079 544067926
473165155 712695184
842055718 911364840
851679243 902318577
17646538 250896470
562282480 742028793
60193924 133595743
573222241 649040970
189379234 223207847
301595726 418600362
105036855 417168695
446368438 622701955
89667978 235369723
2...

output:

No
No
Yes
10 11 14
2 3 15
6 16 4
9 7 18
8 17 12
5 13 1
No
Yes
15 10 12
1 9 4
7 18 5
11 14 16
17 2 6
3 8 13
Yes
5 17 14
3 11 15
8 4 1
6 2 18
10 9 16
12 7 13
Yes
1 13 14
7 10 9
15 12 4
2 8 3
17 6 11
18 5 16
No
Yes
7 8 3
1 16 4
18 12 14
9 15 13
10 5 6
17 2 11
Yes
9 3 8
1 16 7
14 12 6
17 11 18
2 15 4
10...

result:

ok >_< (16666 test cases)

Test #8:

score: 0
Accepted
time: 61ms
memory: 3584kb

input:

14285
7
498283426 941492387
435838088 449924898
60069608 378192988
2943111 147499872
449114197 837331700
157821356 576579017
175187302 188696560
119961285 669031820
613970072 826908873
631375408 817438988
79062948 370271596
137867063 638740575
161249104 439482552
40882880 335796176
97823227 25908403...

output:

Yes
21 15 4
14 11 7
13 16 3
6 20 2
8 18 12
10 9 17
1 19 5
No
Yes
17 13 1
12 16 20
5 21 8
11 15 6
18 7 14
19 3 10
9 2 4
Yes
16 18 5
1 11 2
4 13 10
17 12 15
20 21 9
19 6 14
7 3 8
Yes
21 10 19
20 3 9
2 6 12
15 16 5
14 8 7
18 4 17
13 11 1
No
No
No
No
No
No
No
Yes
11 20 3
9 10 5
17 16 14
13 4 2
1 15 18
8...

result:

ok >_< (14285 test cases)

Test #9:

score: 0
Accepted
time: 64ms
memory: 3584kb

input:

12500
8
109970553 824608515
38308643 43705451
617662368 652509537
56888590 317463343
17277529 58265855
96899941 250839457
10202459 126496650
221863474 331193631
98584951 255380788
66986639 690869710
118913405 222368048
3832128 8623893
411234159 461796409
101768229 194114590
63466173 137574156
159144...

output:

No
No
Yes
2 19 6
5 16 1
12 3 11
15 8 20
23 14 7
17 22 21
10 13 18
9 4 24
No
No
No
Yes
18 1 9
14 6 5
12 7 17
21 19 13
4 16 3
11 20 15
22 24 10
2 23 8
Yes
2 3 23
5 6 1
22 11 8
15 19 16
17 13 9
10 7 24
18 20 14
12 4 21
No
Yes
12 10 7
21 8 14
4 19 20
2 22 5
23 15 18
24 3 13
1 16 17
11 6 9
Yes
17 22 10
1...

result:

ok >_< (12500 test cases)

Test #10:

score: 0
Accepted
time: 67ms
memory: 3712kb

input:

11111
9
1107549 2691939
298974391 782710197
175975837 631858791
80573957 752268030
44807884 279200011
318005100 630132600
130445116 769329445
230959195 258196658
67434329 538628510
126840838 859267729
426717264 514655989
280881449 523731402
150265596 189142970
138881978 907208811
12171267 161288468
...

output:

No
Yes
26 1 19
8 14 12
7 27 23
20 17 25
3 10 24
13 22 4
11 6 9
15 5 18
21 2 16
Yes
10 23 18
6 16 15
17 21 19
11 2 13
27 26 20
12 8 1
22 7 3
4 24 5
9 25 14
No
Yes
17 22 6
14 15 13
5 18 12
4 27 16
7 9 21
19 23 11
10 8 26
25 2 24
3 20 1
Yes
27 6 3
8 21 15
20 22 5
14 19 17
1 13 24
11 12 26
7 23 25
10 2 ...

result:

ok >_< (11111 test cases)

Test #11:

score: 0
Accepted
time: 69ms
memory: 3584kb

input:

10000
10
419583132 802030518
503473132 640274071
29114694 71550121
266502879 799843967
519878600 796619138
109163155 223219513
173801057 312183499
295274161 673542337
569813861 879397647
566104761 631413076
40006012 579868000
45494915 126195703
211345072 535526356
507966667 653535984
868289731 87922...

output:

No
No
No
No
No
No
Yes
9 1 7
24 2 15
8 13 6
17 27 5
19 26 22
16 30 12
3 23 14
11 25 21
4 18 29
28 10 20
No
No
No
No
No
No
No
Yes
21 10 26
4 3 8
28 12 25
13 15 23
30 24 19
11 18 27
9 16 20
29 14 2
1 5 6
7 17 22
No
Yes
9 14 19
26 27 8
25 17 12
29 13 3
15 21 4
20 7 6
24 10 16
22 30 11
2 5 28
18 23 1
Yes...

result:

ok >_< (10000 test cases)

Test #12:

score: 0
Accepted
time: 71ms
memory: 3584kb

input:

5000
20
248930144 452405440
28850950 509061481
11675144 16115810
46552920 66743034
250304676 677780684
13100349 208050516
401412088 954478790
27263447 387546138
341164513 641889899
343680066 717802881
119096072 661699500
675285710 759454419
90875780 255743179
294553111 694729965
146519548 862937826
...

output:

No
Yes
25 53 42
49 43 5
52 11 38
47 28 30
36 29 26
13 57 10
32 41 17
9 60 6
39 22 24
2 12 19
20 33 58
34 56 7
50 8 35
15 21 44
18 16 1
59 14 54
51 27 37
48 3 23
46 45 31
55 40 4
Yes
37 40 21
2 19 12
27 25 13
7 57 47
44 5 1
48 35 55
10 53 18
41 28 42
17 38 8
59 23 46
16 34 36
60 49 50
9 39 15
31 56 4...

result:

ok >_< (5000 test cases)

Test #13:

score: 0
Accepted
time: 79ms
memory: 3584kb

input:

2500
40
30078839 43603670
585409830 661220621
47019446 315312595
195376102 450798063
12047273 30038366
6365574 32488330
44528676 63719100
45395244 370843342
42359492 166874404
189032198 330773980
229782995 560521283
338711259 466163339
486437793 995663034
47493303 362533606
574415501 975584927
63051...

output:

Yes
80 5 21
92 45 6
102 75 1
7 9 103
16 114 22
31 88 55
108 64 30
107 66 35
41 18 27
3 95 52
10 70 19
14 8 91
117 109 42
100 68 20
110 37 84
106 115 4
36 73 12
17 24 65
116 78 33
105 61 120
47 85 71
81 44 11
67 34 46
25 113 96
49 90 53
72 43 40
50 2 63
97 62 54
74 112 58
104 48 82
23 79 38
99 69 56
...

result:

ok >_< (2500 test cases)

Test #14:

score: 0
Accepted
time: 82ms
memory: 3584kb

input:

2000
50
167005 134170081
119263013 235040736
359376356 405102476
368254760 567954026
142560899 351391400
52465572 872095141
5895182 116079799
503946453 935104039
624910603 779623552
407602577 857355273
104834774 642352783
377070248 394389351
7487217 10847154
78697148 403727586
19118138 104520573
302...

output:

No
Yes
110 37 74
12 27 90
129 18 127
106 117 9
2 79 149
42 77 115
143 67 46
98 145 71
66 54 75
23 39 88
32 68 124
56 70 102
47 80 105
91 139 94
134 25 130
20 4 113
3 53 111
33 147 112
81 69 100
84 137 114
109 62 96
10 58 60
108 150 36
121 5 11
45 22 119
78 38 16
95 59 123
72 140 35
1 63 31
116 92 50...

result:

ok >_< (2000 test cases)

Test #15:

score: 0
Accepted
time: 93ms
memory: 3840kb

input:

200
500
240044454 570226789
326748706 906240738
59915230 229227123
25870484 122983289
308323481 491439677
331521117 542348836
79780138 236140577
37215732 400441450
491421004 505626478
41928148 79419397
196402648 681911017
108323645 778854244
168295325 331859787
204653768 764539434
3525633 67848640
2...

output:

Yes
426 912 739
1103 243 78
184 379 1125
27 1094 254
1084 1038 96
1228 451 99
661 980 332
1062 377 314
452 609 595
522 605 1213
1162 1253 68
370 1270 1168
854 1347 197
235 1114 585
473 1333 1286
756 1452 1194
835 761 1294
838 689 478
1132 650 1497
1418 248 842
691 1013 122
834 483 1185
1182 259 390
...

result:

ok >_< (200 test cases)

Test #16:

score: 0
Accepted
time: 104ms
memory: 4284kb

input:

20
5000
239015031 756662829
107482861 164615679
141286392 176745065
711024070 930641599
203753862 992714840
535460189 890646201
120990575 828015603
80241903 245741385
71064502 937343509
255954224 804090603
241085164 265947390
573467935 767999938
9086606 20283091
44079769 135162900
195630455 72443138...

output:

Yes
10270 5391 782
2315 12414 7067
523 5348 13464
12517 4925 4336
14692 13106 6636
2325 6756 10807
10715 14132 13049
9082 4235 11495
6096 1931 9235
5268 11842 14188
7318 7887 11606
14825 7899 13239
8334 5605 3386
1935 10282 224
14682 11137 7373
9904 1606 9590
6172 4178 14372
2200 13791 11189
9109 14...

result:

ok >_< (20 test cases)

Test #17:

score: 0
Accepted
time: 75ms
memory: 10952kb

input:

2
50000
134099372 138717692
88497176 203623137
28400878 531963161
491599270 508595246
656123949 690513632
506593350 840717696
75151479 190312317
138082662 708771391
441148125 893057843
452806396 741239078
42068396 78667991
585159549 926735558
695533088 854308946
676238139 709752322
416586658 6449615...

output:

No
No

result:

ok >_< (2 test cases)

Test #18:

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

input:

1
100000
168698075 217141764
51605261 710454586
17380477 789075415
570367 24849107
469495633 685675008
559954719 839804815
332883788 638763480
12087643 327755609
8406881 43827967
108436258 390187172
266381263 301370841
563550486 622696676
204362703 598237196
218501304 232099091
198720699 211987715
7...

output:

Yes
168460 104318 256556
54783 185038 223132
285307 113271 138877
119294 131392 190167
177081 10206 42602
94428 135424 171507
260297 152820 178849
276798 10541 101955
6942 130237 107547
112260 257523 211032
110233 231361 286195
123607 241652 160244
82840 178241 99138
157695 105354 65216
112726 19541...

result:

ok >_< (1 test case)

Test #19:

score: 0
Accepted
time: 96ms
memory: 3712kb

input:

333
300
499999940 500000540
499999880 500000480
499999882 500000482
500000108 500000110
499999706 500000306
500000286 500000288
499999742 500000342
500000500 500000502
499999773 500000373
500000184 500000186
500000090 500000092
500000010 500000012
499999640 500000240
499999830 500000430
499999945 50...

output:

Yes
637 347 821
462 597 670
407 655 719
298 611 834
625 369 761
668 12 810
18 182 343
475 264 616
483 98 473
29 69 661
762 43 512
175 176 334
844 33 480
345 84 437
249 537 171
500 123 647
609 211 833
622 141 419
82 213 234
656 144 575
466 588 199
672 36 709
71 49 147
394 97 645
460 350 148
775 102 3...

result:

ok >_< (333 test cases)

Test #20:

score: 0
Accepted
time: 111ms
memory: 4356kb

input:

20
5000
500004916 500004918
499994554 500004554
499994653 500004653
500008346 500008348
499990052 500000052
499998337 500008337
499991225 500001225
500008078 500008080
500001210 500001212
500008800 500008802
499992103 500002103
500007998 500008000
500006906 500006908
499994207 500004207
500009454 50...

output:

Yes
4516 6121 1261
9936 11449 11213
9949 4618 13475
4104 1394 13570
7823 5431 9258
10161 4238 13754
9102 1691 5289
13516 582 12872
14026 2910 3068
13492 8581 8804
208 2754 9484
1167 10154 9342
9447 6959 10666
13070 8088 10028
7701 8819 14935
4902 13283 12807
4223 13557 13441
886 2128 14554
2416 188 ...

result:

ok >_< (20 test cases)

Test #21:

score: 0
Accepted
time: 113ms
memory: 5168kb

input:

10
10000
499997582 500017582
499994226 500014226
499999146 500019146
499986192 500006192
500006688 500006690
500005454 500005456
500012694 500012696
499994423 500014423
500018252 500018254
499984238 500004238
500019624 500019626
500002666 500002668
499981309 500001309
499984412 500004412
499989582 5...

output:

Yes
3571 2784 7133
7744 2889 21093
14515 16631 5592
23969 12741 17082
11488 8185 19725
15427 10657 24164
26263 11891 27110
22169 7000 21721
5158 25335 13925
29844 7938 27632
16020 23705 29520
11007 26145 27453
20675 11116 28622
26583 4796 22235
27261 17604 22975
6493 2902 23356
4523 5639 6303
5729 4...

result:

ok >_< (10 test cases)

Test #22:

score: 0
Accepted
time: 126ms
memory: 21300kb

input:

1
100000
500195974 500195976
499821737 500021737
500032078 500032080
499844833 500044833
500004644 500004646
499896575 500096575
499837203 500037203
500162180 500162182
499803443 500003443
499903390 500103390
499997619 500197619
499983152 500183152
499851444 500051444
500124540 500124542
500090666 5...

output:

Yes
131511 65139 264885
76576 124455 226045
83964 82996 244544
80178 238107 221144
74430 167762 264786
293393 13739 171984
250735 60795 200062
171343 214704 221633
291395 277188 232225
19408 42025 298732
13088 135362 52446
182674 89109 149955
25559 197236 116134
103652 44499 229441
245551 9036 46839...

result:

ok >_< (1 test case)

Test #23:

score: 0
Accepted
time: 89ms
memory: 3840kb

input:

333
300
499999677 500000277
499999937 500000537
499999927 500000527
500000186 500000187
500000577 500000580
499999970 500000570
499999688 500000288
499999779 500000379
499999825 500000425
500000503 500000506
499999429 500000029
499999795 500000395
500000251 500000254
499999853 500000453
499999792 50...

output:

No
Yes
615 528 595
108 338 457
357 59 732
153 433 484
687 408 500
788 567 872
506 101 250
442 358 563
239 85 214
161 424 553
635 261 900
636 20 831
730 657 722
121 829 34
806 609 140
36 873 287
3 400 52
410 309 498
325 97 92
342 777 53
199 507 649
278 479 772
177 62 460
697 91 458
560 74 600
515 648...

result:

ok >_< (333 test cases)

Test #24:

score: 0
Accepted
time: 130ms
memory: 20496kb

input:

1
100000
500191010 500191012
499836328 500036328
499951243 500151243
499935598 500135598
499898653 500098653
499956171 500156171
500101528 500101529
499800616 500000616
500107541 500107543
500158180 500158181
499825597 500025597
500175739 500175742
500076543 500076545
499970418 500170418
500014716 5...

output:

Yes
185289 8827 133749
243919 142806 131627
216300 257868 78069
265642 128874 277867
35978 101065 242428
173722 255534 14900
239643 173490 152359
249724 147928 192333
27661 197591 10842
149171 178375 95794
270097 199144 227306
91148 121891 285165
63655 68961 266432
220577 46166 126038
31828 17783 29...

result:

ok >_< (1 test case)

Extra Test:

score: 0
Extra Test Passed