QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#507388#1652. One PieceGuanYunchangAC ✓73ms30820kbC++202.7kb2024-08-06 17:07:282024-08-06 17:07:30

詳細信息

Test #1:

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

input:

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

output:

3 4 5 1 2 

result:

ok single line: '3 4 5 1 2 '

Test #2:

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

input:

4
2 1
3 2
3 4
1 0 1 2

output:

2 1 3 4

result:

ok single line: '2 1 3 4'

Test #3:

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

input:

1
0

output:

1 

result:

ok single line: '1 '

Test #4:

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

input:

2
1 2
0 1

output:

1 2

result:

ok single line: '1 2'

Test #5:

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

input:

3
2 3
1 2
2 1 1

output:

2 3 1 

result:

ok single line: '2 3 1 '

Test #6:

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

input:

4
3 2
1 4
3 1
1 3 2 1

output:

1 4 2 3 

result:

ok single line: '1 4 2 3 '

Test #7:

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

input:

4
4 3
4 2
1 2
3 2 2 1

output:

2 3 4 1 

result:

ok single line: '2 3 4 1 '

Test #8:

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

input:

4
3 2
1 2
4 1
1 2 3 1

output:

1 4 2 3 

result:

ok single line: '1 4 2 3 '

Test #9:

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

input:

4
3 1
2 3
2 4
3 1 2 0

output:

4 1 2 3 

result:

ok single line: '4 1 2 3 '

Test #10:

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

input:

4
2 4
3 4
1 4
2 2 2 1

output:

1 2 3 4 

result:

ok single line: '1 2 3 4 '

Test #11:

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

input:

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

output:

4 5 1 2 3 

result:

ok single line: '4 5 1 2 3 '

Test #12:

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

input:

5
2 5
3 1
3 4
3 5
0 3 1 2 2

output:

1 2 3 4 5

result:

ok single line: '1 2 3 4 5'

Test #13:

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

input:

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

output:

1 4 2 3 5 

result:

ok single line: '1 4 2 3 5 '

Test #14:

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

input:

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

output:

4 1 5 2 3 

result:

ok single line: '4 1 5 2 3 '

Test #15:

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

input:

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

output:

2 1 4 3 5 

result:

ok single line: '2 1 4 3 5 '

Test #16:

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

input:

6
2 4
6 2
5 2
5 3
1 4
1 1 3 0 2 2

output:

4 1 2 3 5 6

result:

ok single line: '4 1 2 3 5 6'

Test #17:

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

input:

6
3 5
5 6
4 2
2 1
6 1
3 4 3 5 2 2

output:

1 3 5 6 2 4 

result:

ok single line: '1 3 5 6 2 4 '

Test #18:

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

input:

6
5 2
6 5
6 3
4 6
2 1
2 1 4 4 2 3

output:

1 5 2 3 4 6 

result:

ok single line: '1 5 2 3 4 6 '

Test #19:

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

input:

6
1 6
5 6
1 4
2 4
3 5
2 4 2 3 1 1

output:

5 6 1 2 3 4 

result:

ok single line: '5 6 1 2 3 4 '

Test #20:

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

input:

6
4 5
1 3
6 3
3 2
3 5
2 2 1 3 2 2

output:

1 2 5 6 3 4 

result:

ok single line: '1 2 5 6 3 4 '

Test #21:

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

input:

7
7 6
7 5
4 1
3 2
4 7
2 7
3 3 4 2 3 3 2

output:

1 2 5 6 4 7 3 

result:

ok single line: '1 2 5 6 4 7 3 '

Test #22:

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

input:

7
6 7
4 1
3 6
4 7
6 2
5 2
2 3 3 1 4 2 1

output:

4 7 1 2 3 5 6 

result:

ok single line: '4 7 1 2 3 5 6 '

Test #23:

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

input:

7
7 5
4 7
6 7
1 2
3 7
7 2
2 1 2 2 2 2 1

output:

2 7 1 3 4 5 6 

result:

ok single line: '2 7 1 3 4 5 6 '

Test #24:

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

input:

7
4 7
4 1
4 2
5 3
3 7
3 6
2 1 3 1 4 4 2

output:

2 4 1 3 5 6 7 

result:

ok single line: '2 4 1 3 5 6 7 '

Test #25:

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

input:

8
3 4
1 4
1 6
7 4
8 5
4 5
6 2
2 4 2 1 2 3 2 3

output:

1 3 5 7 4 2 6 8 

result:

ok single line: '1 3 5 7 4 2 6 8 '

Test #26:

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

input:

8
7 5
1 7
3 6
7 4
6 7
8 6
2 5
3 4 2 3 3 1 2 1

output:

6 8 1 2 3 4 5 7 

result:

ok single line: '6 8 1 2 3 4 5 7 '

Test #27:

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

input:

8
5 7
1 7
8 7
6 5
3 7
4 5
2 5
3 2 3 1 1 2 2 3

output:

4 5 1 2 3 6 7 8 

result:

ok single line: '4 5 1 2 3 6 7 8 '

Test #28:

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

input:

8
8 7
4 6
2 4
3 8
8 1
8 2
2 5
2 2 2 3 3 4 2 1

output:

1 2 3 7 8 4 5 6 

result:

ok single line: '1 2 3 7 8 4 5 6 '

Test #29:

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

input:

8
3 2
6 1
3 5
3 7
8 2
4 6
6 2
3 2 3 3 4 2 4 3

output:

1 3 4 8 2 6 5 7 

result:

ok single line: '1 3 4 8 2 6 5 7 '

Test #30:

score: 0
Accepted
time: 54ms
memory: 29216kb

input:

250000
27197 102813
107013 109797
16583 152577
164884 11838
214586 173971
248203 141910
7896 111843
80520 130209
6277 128026
55601 234265
95559 88739
152936 50808
194534 24226
159232 83111
103712 33855
142546 246859
40404 81467
125784 239727
24202 165110
57020 155999
133375 118407
156303 150104
1493...

output:

10 23 36 42 44 70 71 101 111 113 116 141 177 183 204 217 221 251 252 253 260 264 271 272 307 318 325 328 338 360 397 423 429 442 494 506 518 521 526 537 564 567 602 633 673 683 721 738 739 744 754 770 827 835 837 865 872 890 893 914 946 948 967 973 981 1003 1014 1063 1068 1083 1118 1133 1152 1166 11...

result:

ok single line: '10 23 36 42 44 70 71 101 111 1...50 249954 249976 249982 249986 '

Test #31:

score: 0
Accepted
time: 62ms
memory: 28288kb

input:

250000
198658 122606
213093 143827
45640 230664
242707 66336
228202 70151
54424 136589
31088 11371
216202 169155
131901 199050
54921 227981
114533 38096
180601 164687
21723 12006
68933 157358
93093 147993
50664 240700
41575 183691
172663 45572
194543 35989
237102 202526
171096 138704
245144 179222
2...

output:

246154 41241 48703 165441 166068 47764 67652 88266 98241 104150 110913 10620 29728 53554 73909 93188 124031 198484 203298 232580 232961 863 1911 6924 11618 29372 30126 40682 59287 79881 84573 89682 104848 108458 116913 121223 132390 133756 144809 145474 150453 174498 179872 181416 191564 214760 2266...

result:

ok single line: '246154 41241 48703 165441 1660...83 249992 249993 249994 249997 '

Test #32:

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

input:

250000
150025 184663
176595 81410
216276 183777
104200 5046
106960 61316
114179 190662
43235 12286
199392 183873
164776 54126
136737 120558
193767 47226
175202 185916
101759 162700
210103 119181
15711 157128
220097 78805
166232 152494
222872 96865
220339 239160
6675 129357
201941 16521
23383 183258
...

output:

86025 144264 210644 212075 79920 86298 98260 165116 175173 179865 194378 221439 235113 3223 14909 27224 41795 59343 72057 169184 175046 179657 184827 196866 248689 40569 67537 96594 146148 165786 165853 45786 99963 127335 179436 186925 208335 228576 2718 35491 38844 76332 158879 164836 181489 192291...

result:

ok single line: '86025 144264 210644 212075 799...94 249995 249996 249998 249999 '

Test #33:

score: 0
Accepted
time: 53ms
memory: 27440kb

input:

250000
206619 242105
239794 18130
181483 72263
220661 221119
114740 66047
220282 84654
29537 130596
23235 75950
239067 6673
56521 4875
73300 89857
213006 225702
230846 172828
239964 42517
71524 43210
76051 139913
209733 81352
158304 84038
205593 68193
55920 249128
247854 139470
29992 230810
74863 14...

output:

14 33 34 142 154 182 322 345 386 396 441 446 545 637 647 759 763 811 846 849 876 1167 1202 1250 1350 1477 1497 1536 1639 1671 1694 1831 1832 1846 1898 1935 1942 2073 2098 2233 2277 2359 2572 2589 2617 2644 2698 2779 2797 2813 2824 2836 2895 2915 3004 3020 3033 3047 3073 3126 3169 3176 3369 3417 3430...

result:

ok single line: '14 33 34 142 154 182 322 345 3...78 249980 249981 249986 249993 '

Test #34:

score: 0
Accepted
time: 62ms
memory: 28840kb

input:

250000
75521 175895
160013 76361
16757 237513
213606 90234
149019 200868
52309 154421
39018 80657
101435 154502
34093 46323
231582 107375
206790 141494
70535 104073
167950 39698
199986 242858
13161 37880
244623 246494
14672 94439
123032 3395
184776 226443
75610 66222
17418 30856
34162 197559
79318 8...

output:

46158 127633 227634 64817 115224 177986 208082 11031 45213 167890 169893 206196 5667 40808 48925 71810 136162 156346 186201 229824 246519 17292 72744 93315 132680 148788 150015 178671 189577 225465 233470 332 12629 20855 25645 35489 79473 119997 122242 142313 178975 202286 222911 1680 50864 69522 73...

result:

ok single line: '46158 127633 227634 64817 1152...90 249623 249669 249761 250000 '

Test #35:

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

input:

250000
246191 176844
109683 28166
33163 188939
219063 209733
249527 110553
102019 43221
49089 171423
181608 177905
114640 166296
26308 51123
92421 236014
72180 98499
243524 176458
170890 102492
46620 232836
181886 246412
8542 181098
28876 80627
5450 133347
243394 47523
38721 232936
6274 41638
18056 ...

output:

125320 18580 172155 231351 31369 77079 77713 84103 97977 134391 172297 198928 30305 32292 48230 73735 75717 116722 148560 173105 179504 212866 231316 2487 28320 34039 56245 56261 78873 92840 115216 116695 143127 164713 235761 1342 14322 21375 40304 55352 68205 69036 95647 117814 194728 211357 213775...

result:

ok single line: '125320 18580 172155 231351 313...53 249959 249976 249983 249995 '

Test #36:

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

input:

250000
20810 166053
107520 241105
104276 189446
96716 170266
40518 119870
139799 175224
57676 159984
4938 144536
249126 200740
225274 35358
53679 127362
52340 154685
217180 4024
112200 76930
227523 2403
56003 109358
36828 210683
91848 6390
107329 199146
92248 109555
183091 54903
6545 90285
206247 21...

output:

74 123 178 282 365 627 923 950 1032 1035 1192 1331 1439 2207 2254 2290 2483 2553 2599 2601 2739 2912 2914 2992 3219 3261 3312 3317 3408 3531 3990 4073 4122 4473 4528 4745 4914 4922 5103 5205 5355 5363 5382 5501 5562 5730 5828 5915 6193 6249 6284 6480 6722 6780 7132 7154 7379 7431 7638 7934 8101 8360...

result:

ok single line: '74 123 178 282 365 627 923 950...88 249989 249990 249994 249996 '

Test #37:

score: 0
Accepted
time: 41ms
memory: 28768kb

input:

250000
55080 142175
162847 104534
109916 73121
175095 237616
83349 126514
186470 213464
136042 3261
73525 211168
23539 28468
104539 188203
63967 221679
30880 162886
238745 125082
119629 33242
138163 238309
170896 74379
195853 3115
80869 208724
183250 40633
210170 229148
226317 116817
199383 134233
9...

output:

645 936 1104 1127 1367 1847 2226 2289 2433 2636 2868 3104 3219 3227 3409 3524 3898 4025 4068 4207 4329 5397 5594 5634 5713 6145 6501 7356 7448 7694 7732 7926 8142 8733 9624 9844 10251 10979 11023 11098 11538 11596 12222 12444 12625 12835 12851 12992 13042 13718 14145 14183 14223 14496 14601 14752 14...

result:

ok single line: '645 936 1104 1127 1367 1847 22...65 249968 249971 249982 249992 '

Test #38:

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

input:

250000
13408 87188
76513 45729
128670 17363
193596 130739
182461 43740
206708 40685
243596 114691
34493 100705
79481 218170
52785 208132
217016 152535
8189 157211
144894 82270
171551 50664
53315 12481
100991 45897
23516 32779
160422 84225
211817 210833
235356 5867
129593 183366
153004 54481
204509 8...

output:

46 136 385 476 502 639 1024 1068 1459 1859 2684 2921 2940 3617 3987 4129 4215 4229 4513 4560 4951 5248 5403 5502 5650 6071 6907 7579 7694 7781 8137 8432 8655 9293 9390 9675 10169 10221 10537 10996 11278 11720 12582 12790 13000 13174 13332 13368 13512 14147 15437 15461 15623 15903 16186 16774 17233 1...

result:

ok single line: '46 136 385 476 502 639 1024 10...93 249995 249996 249997 250000 '

Test #39:

score: 0
Accepted
time: 47ms
memory: 30600kb

input:

250000
249978 246460
129623 126008
132995 92493
161731 185044
179900 224573
155658 44943
132342 246003
123491 187133
57603 42325
26412 58438
55938 99055
68699 83740
12738 155057
45653 85401
91540 157334
190123 140205
159312 78599
102075 3471
50306 94583
83017 62435
33380 218027
195499 3668
24264 225...

output:

189203 224076 234255 41057 45913 55006 92395 215696 229963 8824 25454 72153 76824 128388 131966 151247 159983 169178 216764 25896 63520 78073 87893 96598 110963 128852 136188 177104 229739 231693 3821 12044 17165 19308 23403 37094 44833 46866 50898 52296 61877 71870 76590 84113 101716 108686 113005 ...

result:

ok single line: '189203 224076 234255 41057 459...90 249991 249992 249993 249994 '

Test #40:

score: 0
Accepted
time: 46ms
memory: 28268kb

input:

250000
245639 237279
48079 44800
91957 128814
77974 176194
103383 179937
174306 199264
49937 54322
191902 173957
22742 142222
249708 3143
30870 228101
25653 154641
33283 38586
120940 192577
70457 162612
220584 49074
230614 59090
200469 174332
47862 9757
19376 207686
115936 40416
218187 188785
160463...

output:

18 35 45 54 56 58 67 68 87 111 122 129 143 157 171 240 252 276 278 281 287 290 297 313 314 348 381 408 432 448 450 471 474 476 493 523 525 543 546 575 577 593 602 616 640 644 645 657 672 674 685 700 711 726 770 776 811 824 832 837 840 849 857 858 879 894 906 928 937 947 948 950 967 975 994 999 1008 ...

result:

ok single line: '18 35 45 54 56 58 67 68 87 111...92 249994 249995 249996 249999 '

Test #41:

score: 0
Accepted
time: 50ms
memory: 27584kb

input:

250000
246608 239476
216200 179608
16230 71001
75897 35374
186861 249640
112178 71025
194832 39536
18797 178410
29624 144431
50450 11349
24310 229955
102730 85606
117691 188997
126532 96564
198337 224216
16413 127982
237416 56693
208884 240372
2355 94870
152955 166489
164776 127868
172961 44588
1308...

output:

182 296 410 526 534 544 631 640 705 816 830 1395 1558 1627 1658 1992 2037 2088 2181 2193 2227 2277 2492 2711 2854 2867 2886 2898 2906 2922 3052 3277 3420 3436 3437 3868 3877 3902 4079 4141 4539 4540 4636 4659 4717 4920 4927 4986 5090 5370 5417 5561 5658 5777 6013 6156 6846 6957 7137 7191 7314 7340 7...

result:

ok single line: '182 296 410 526 534 544 631 64...95 249996 249997 249999 250000 '

Test #42:

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

input:

250000
99879 147453
164980 152817
214723 31351
52578 242545
82864 50088
9138 158706
72903 178146
216787 230327
102337 177063
86764 30215
245685 78022
6063 10142
107473 12444
189559 143542
156967 161781
115366 248558
60731 50503
164911 10387
193245 176434
224412 125537
185964 245245
4919 127271
16848...

output:

42585 199380 210781 215773 223514 18818 20905 59457 82186 82442 101923 139389 147545 174535 178058 191160 209955 48901 72590 134391 235537 5594 21681 23579 30172 42913 47838 60654 71191 88431 112309 122758 130442 152460 175983 190332 193401 229939 241421 244863 248496 589 16633 19114 89641 121675 14...

result:

ok single line: '42585 199380 210781 215773 223...95 249996 249998 249999 250000 '

Test #43:

score: 0
Accepted
time: 50ms
memory: 30820kb

input:

250000
207984 153170
36833 82602
204971 99103
55175 74859
78037 233661
94374 27171
37917 50625
98144 146269
104937 227060
149600 238007
103896 111779
174884 80167
35682 60840
134510 203509
206746 137080
233558 100734
180512 126569
48653 47881
179217 50775
4557 14546
127239 15237
246656 85462
95556 3...

output:

194181 203426 24802 29364 42587 69948 73859 163815 219951 237916 16626 38419 174872 51511 84319 85408 109900 53061 154394 171945 173920 201312 245401 14472 28936 124909 134109 140049 155436 228007 229732 242331 1310 10549 20322 44683 104676 156254 162992 171646 243102 248314 8310 27860 36689 45039 5...

result:

ok single line: '194181 203426 24802 29364 4258...94 249996 249998 249999 250000 '

Test #44:

score: 0
Accepted
time: 65ms
memory: 29104kb

input:

250000
163314 57507
69734 193165
123449 236990
105287 109128
68624 55639
213276 62383
114134 108651
249227 49651
241463 162315
195036 140899
236529 247612
70009 234647
27665 6363
90899 133462
205698 245294
122243 146597
44489 7903
44608 194267
171655 209886
219728 138927
212971 41783
81646 70404
181...

output:

143 1498 1709 2144 2282 2492 3402 3676 5130 5258 5731 5813 6749 6932 7121 7673 8256 8366 9157 9169 9569 9576 9724 10430 10771 11864 12053 13099 13468 13482 15442 15607 16060 16763 17264 18207 19153 19247 19603 20289 20603 20856 21651 23687 24105 24185 24437 24667 24924 25608 25671 25852 26327 26464 ...

result:

ok single line: '143 1498 1709 2144 2282 2492 3...92 249996 249997 249998 249999 '

Test #45:

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

input:

250000
211022 152359
9949 236774
127329 10491
73790 99664
194758 12597
171541 153892
104889 123694
223693 98053
162937 208923
188740 148113
70033 22447
145781 75889
1921 177844
188054 185129
164484 249621
248215 222657
238223 39104
139508 247042
231960 10782
115132 120920
100049 25976
36344 119487
9...

output:

183 427 485 524 566 651 723 742 862 1051 1159 1576 2080 3468 3629 3908 4179 4254 4844 4845 5168 5479 6012 6043 6864 7457 8086 9298 9327 9580 9641 9899 10404 11899 12553 12687 12801 13304 13612 13626 13670 13698 13864 13966 14197 14705 14808 15035 15087 15218 15373 15494 15524 15804 15818 15897 15898...

result:

ok single line: '183 427 485 524 566 651 723 74...96 249997 249998 249999 250000 '

Test #46:

score: 0
Accepted
time: 50ms
memory: 29332kb

input:

250000
7795 153529
99227 2050
13478 224348
60461 79042
216012 4433
141733 211305
181153 174873
221832 204076
45739 65272
38718 34554
131228 88270
20541 6036
2340 54675
109808 154195
140191 18784
228039 236782
243461 178615
108792 136574
179036 224916
84395 86676
1111 611
24113 93521
58457 67049
1753...

output:

176765 190182 249162 98245 140664 166492 204580 216935 238099 37964 59432 73730 74804 79968 108995 158313 166057 176770 187771 200051 203694 207189 221104 237304 12707 129739 185940 207546 233098 243552 244156 6770 42800 47880 49752 51769 55164 80133 148293 177102 224110 230235 5637 10009 11393 5143...

result:

ok single line: '176765 190182 249162 98245 140...85 249992 249997 249998 250000 '

Test #47:

score: 0
Accepted
time: 65ms
memory: 27752kb

input:

250000
170472 131688
2712 157307
85904 161573
6780 88499
46384 192347
225240 237901
91377 155749
186882 19881
206995 222733
96395 125995
228652 249167
235958 34126
176741 165536
38659 201668
238840 52193
60095 207007
217591 248854
189449 38005
109610 35435
129235 16642
193672 94289
45006 134867
9457...

output:

86 481 527 1192 1776 2011 2276 2684 2943 3470 3651 4026 4207 4246 4270 4783 5025 5196 5553 5846 6086 6889 7180 7338 7670 7860 8272 8319 8700 9164 9664 9694 9782 9846 10071 10510 11020 11601 12226 12351 13369 13591 13678 13850 14086 14100 14382 14412 14486 14909 16769 16836 17124 17406 17821 18087 19...

result:

ok single line: '86 481 527 1192 1776 2011 2276...95 249996 249997 249998 250000 '

Test #48:

score: 0
Accepted
time: 43ms
memory: 28012kb

input:

250000
146932 241510
229031 81075
159879 247182
116480 155728
26354 219312
171275 34787
223265 108939
112383 66424
248628 128746
67066 205627
209641 237226
195801 145082
4852 130737
148409 187560
43191 229837
161443 168178
167888 164694
139357 176170
35730 112495
74445 60435
95727 40063
199905 18093...

output:

462 816 1028 1056 1074 1091 1443 2221 2720 3997 4204 4223 4349 4400 4425 4462 4874 5027 5043 5403 6070 6364 6663 6848 7212 7424 7494 7599 7715 7939 8478 8869 8879 8891 9131 9138 9942 10054 10461 10659 10827 10903 10937 11166 11341 11742 11766 11911 13455 13517 13661 13857 14682 15153 15612 15681 161...

result:

ok single line: '462 816 1028 1056 1074 1091 14...95 249996 249997 249998 249999 '

Test #49:

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

input:

250000
167883 42499
124217 229049
13148 7120
42771 228803
67876 118563
249002 79531
197275 95251
77379 49077
116086 229080
11959 81143
74467 189301
5039 150978
211404 179983
225388 54922
142772 228150
37214 237832
85665 151208
121549 63218
131035 203306
130433 45930
84765 233718
182529 127502
186745...

output:

37 79 355 563 831 872 1160 1274 1351 1606 2094 2300 2339 2486 2532 2575 2872 3748 4292 5347 5552 5762 5970 6353 6919 7230 7257 7666 8710 9291 9852 10124 10320 11052 11316 11456 11478 11578 11617 11799 12268 12316 12498 12704 13070 13085 14198 14772 16431 16438 16807 17106 17903 18149 18504 18641 188...

result:

ok single line: '37 79 355 563 831 872 1160 127...90 249991 249992 249998 249999 '

Test #50:

score: 0
Accepted
time: 54ms
memory: 28708kb

input:

250000
142309 124033
165834 94468
187855 229771
26631 114153
85207 76267
85597 127147
199442 102673
97959 121247
142831 76780
200061 192011
225082 183653
225756 71535
223605 161304
1547 9448
189740 8987
95701 155704
207495 155406
157177 222364
149630 217126
177119 31058
3629 248316
213408 142842
125...

output:

242174 243669 34229 49902 146614 130145 134803 169866 230958 245233 10205 21445 46517 82564 113092 153516 201799 202357 246556 246765 8375 67793 80011 85895 140970 142584 143366 158844 187326 203561 210478 211198 231157 246163 1289 9344 10560 16965 27115 28275 29475 29589 31551 44094 47301 55676 612...

result:

ok single line: '242174 243669 34229 49902 1466...70 249976 249988 249995 250000 '

Test #51:

score: 0
Accepted
time: 50ms
memory: 27664kb

input:

250000
173288 150763
26929 37160
139906 22525
10002 40640
78815 17671
150890 79404
25378 35776
147675 59930
153194 33483
70392 106947
148450 75990
243079 14237
67946 45326
185194 64991
87257 233264
124284 194741
122239 11977
64033 211139
72978 157294
121464 155752
138798 111777
243544 239005
217471 ...

output:

218 243 423 765 862 914 1254 1542 1555 1581 1621 1837 2120 2258 2323 2529 2626 2644 2697 2835 3024 3051 3110 3317 3400 3429 3722 3900 3944 4015 4179 4438 4767 5348 5551 5981 6091 6290 6316 6444 6491 6494 6499 6662 6783 6845 6869 7209 7590 7749 7945 8090 8258 8348 8355 8391 8880 8923 8953 8971 9033 9...

result:

ok single line: '218 243 423 765 862 914 1254 1...89 249990 249991 249992 249999 '

Test #52:

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

input:

250000
8142 144871
14813 82166
44086 125181
91185 223119
141263 114945
100736 16519
110395 126053
150437 173411
8033 206596
23461 233916
182040 206970
202537 161673
10372 57595
148645 37294
63761 215957
71249 213538
154627 232658
116072 17260
183845 55343
212781 172090
150105 197102
131575 197685
24...

output:

84 159 203 292 351 441 529 548 567 683 740 758 763 791 870 895 937 938 1015 1030 1048 1088 1098 1196 1212 1255 1519 1521 1522 1530 1531 1638 1684 1752 1772 1808 1818 1827 1865 1988 2003 2032 2061 2122 2354 2433 2488 2490 2575 2579 2582 2656 2703 2724 2727 2730 2759 2770 2771 2791 2809 2849 2859 2889...

result:

ok single line: '84 159 203 292 351 441 529 548...93 249994 249996 249998 249999 '

Test #53:

score: 0
Accepted
time: 50ms
memory: 27968kb

input:

250000
163662 161313
132119 10642
207904 24634
138722 115985
110681 106563
177403 212692
230866 189600
199965 169242
12907 26164
34170 236950
54944 175351
119276 69422
104328 247871
170216 164876
172597 195598
207897 131351
48244 98828
99799 85321
160782 55921
137629 125566
77895 80076
148167 63185
...

output:

1 16 32 41 97 98 110 128 133 147 268 293 346 353 356 361 391 392 393 431 467 480 490 503 519 541 546 548 556 624 653 662 685 710 713 719 778 781 783 795 813 839 842 852 865 871 877 883 959 978 986 990 994 1008 1016 1047 1065 1089 1108 1128 1137 1148 1156 1158 1163 1165 1206 1213 1215 1268 1289 1318 ...

result:

ok single line: '1 16 32 41 97 98 110 128 133 1...94 249997 249998 249999 250000 '

Test #54:

score: 0
Accepted
time: 73ms
memory: 27968kb

input:

250000
221545 222607
51044 37818
97670 242418
42935 154500
215797 8890
109607 220429
249053 154387
198979 211569
154274 197778
116893 21306
53096 45824
32983 153733
158163 130535
81748 16297
173745 1978
24552 153053
221800 18970
133987 120572
146074 249340
227540 20379
201165 33025
77783 119339
1025...

output:

10242 11106 13653 15553 18972 18997 20032 20131 21237 22906 25129 25212 26501 26691 34801 38194 38799 42052 42451 42724 43398 44046 44614 47225 49936 51762 52191 52477 59883 60681 60823 64620 65120 65455 65771 66854 67903 69224 70341 71859 73153 73180 74910 75657 78600 81419 83963 84189 86028 89290 ...

result:

ok single line: '10242 11106 13653 15553 18972 ...96 249997 249998 249999 250000 '

Test #55:

score: 0
Accepted
time: 41ms
memory: 28192kb

input:

250000
205496 126089
51685 32718
178765 5041
222328 167778
99208 117425
175617 6109
66842 227322
5934 125518
82188 24847
27011 189751
70289 125043
21557 145905
183007 240212
6807 126272
132176 208061
164138 191413
232807 82011
24941 204349
30294 197134
103941 166800
26500 23262
111739 242889
134683 ...

output:

109 252 297 526 714 759 851 861 904 936 945 952 1208 1342 1486 1507 1541 1592 1650 1691 1787 1897 1960 2047 2223 2386 2389 2658 2675 2817 2833 2950 2972 3118 3138 3468 3548 3738 3790 3878 3926 4048 4111 4141 4144 4349 4358 4375 4395 4399 4415 4570 4659 4705 4821 4963 4987 4994 5025 5027 5078 5085 51...

result:

ok single line: '109 252 297 526 714 759 851 86...68 249972 249981 249983 250000 '