QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#468450 | #4989. Berry Battle | ZhangYiDe | AC ✓ | 316ms | 35184kb | C++17 | 868b | 2024-07-08 20:50:08 | 2024-07-08 20:50:09 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 4ms
memory: 14792kb
input:
10 1 2 2 3 3 4 3 9 3 7 7 10 1 5 5 6 1 8
output:
YES 7 10 3 2 1 5 6 8 4 9
result:
ok
Test #2:
score: 0
Accepted
time: 0ms
memory: 14780kb
input:
3 1 2 2 3
output:
NO
result:
ok
Test #3:
score: 0
Accepted
time: 0ms
memory: 14940kb
input:
3 1 3 3 2
output:
NO
result:
ok
Test #4:
score: 0
Accepted
time: 0ms
memory: 14820kb
input:
4 2 4 4 1 3 4
output:
NO
result:
ok
Test #5:
score: 0
Accepted
time: 3ms
memory: 14764kb
input:
5 5 3 2 1 4 5 3 1
output:
YES 5 4 3 1 2
result:
ok
Test #6:
score: 0
Accepted
time: 0ms
memory: 14784kb
input:
6 1 2 6 5 5 2 3 4 4 2
output:
YES 4 3 2 1 5 6
result:
ok
Test #7:
score: 0
Accepted
time: 0ms
memory: 14948kb
input:
10 8 4 3 5 9 10 10 6 4 6 1 10 7 10 2 4 5 7
output:
YES 4 2 8 6 10 9 1 7 5 3
result:
ok
Test #8:
score: 0
Accepted
time: 4ms
memory: 14744kb
input:
100 42 8 32 6 92 57 47 76 69 34 24 20 61 57 22 10 18 26 89 64 13 76 38 34 23 34 54 69 88 26 66 95 34 2 93 80 77 56 96 10 44 91 86 1 90 26 19 56 30 10 4 30 45 6 8 34 17 37 97 73 67 19 58 65 75 74 39 20 57 71 53 45 25 90 51 1 79 22 55 54 15 76 74 11 70 2 95 34 60 25 91 34 48 58 16 57 64 76 37 11 40 9 ...
output:
YES 19 67 56 77 22 10 96 41 30 4 21 72 12 100 43 53 45 6 32 33 27 36 62 85 5 20 24 39 83 2 34 69 54 55 50 38 81 11 74 75 37 17 52 14 82 35 23 8 42 95 66 84 49 91 44 98 99 94 46 70 71 57 92 7 61 28 16 31 1 86 51 9 40 73 97 68 78 63 80 93 26 18 88 65 58 48 29 76 47 13 15 87 64 89 3 90 25 60 59 79
result:
ok
Test #9:
score: 0
Accepted
time: 0ms
memory: 14704kb
input:
200 16 122 183 100 132 29 72 90 127 78 31 151 133 8 161 93 49 103 131 113 121 59 60 15 44 183 130 105 155 170 192 191 156 167 95 85 163 77 154 41 199 101 103 158 20 68 54 2 114 50 167 128 149 166 21 141 119 110 170 73 63 19 33 154 120 124 151 113 26 187 15 112 91 83 70 194 51 197 116 6 176 158 175 1...
output:
YES 147 67 172 66 80 187 26 86 181 59 121 169 196 182 10 150 105 130 43 99 89 191 192 111 48 97 34 134 146 41 154 33 32 35 14 101 199 115 9 128 167 156 159 113 131 151 31 137 148 75 30 37 84 193 175 69 74 46 61 6 116 100 183 44 78 127 3 138 55 76 123 38 186 195 57 13 52 104 162 7 94 64 125 190 184 2...
result:
ok
Test #10:
score: 0
Accepted
time: 5ms
memory: 14864kb
input:
200 56 198 56 128 56 76 56 90 56 155 56 32 56 55 56 1 56 83 56 59 56 133 56 115 56 30 56 131 56 40 56 177 56 166 56 63 56 104 56 13 56 164 56 152 56 47 56 38 56 127 56 199 56 145 56 20 56 36 56 46 56 137 56 190 56 146 56 183 56 187 56 6 56 194 56 77 56 160 56 138 56 149 56 64 56 100 56 117 56 27 56 ...
output:
NO
result:
ok
Test #11:
score: 0
Accepted
time: 0ms
memory: 14832kb
input:
200 3 138 3 187 3 13 3 36 3 26 3 59 3 69 3 54 3 27 3 154 3 82 3 132 3 161 3 101 3 198 3 6 3 193 3 169 3 60 3 85 3 166 3 57 3 28 3 163 3 89 3 93 3 135 3 16 3 125 3 62 3 71 3 150 3 2 3 21 3 127 3 121 3 95 3 39 3 179 3 90 3 98 3 104 3 182 3 103 3 177 3 174 3 172 3 49 3 88 3 178 3 51 3 200 3 159 3 48 3 ...
output:
YES 86 134 48 3 138 187 13 36 26 59 69 54 27 154 82 132 161 101 45 198 6 193 169 60 85 166 57 28 163 75 162 89 93 135 16 125 62 71 150 2 21 127 38 121 95 39 179 90 98 104 182 103 177 112 174 172 43 188 49 88 178 51 200 159 155 32 151 114 147 157 107 140 19 64 80 15 105 175 199 165 130 22 66 68 164 5...
result:
ok
Test #12:
score: 0
Accepted
time: 217ms
memory: 26104kb
input:
300000 114853 264153 298031 43573 189277 96893 68911 129144 83395 244009 1019 185588 39660 143053 246340 144880 244223 132708 152084 27057 230030 57377 141813 235567 64190 230887 105772 151822 258236 227531 184923 92096 66128 16467 199270 173492 78538 249107 232394 197343 268822 246960 281154 197354...
output:
YES 156884 157874 271039 194940 232733 115373 160355 264922 208485 253126 122888 57182 180718 239047 70927 116193 156402 299046 151454 127442 157384 253998 216051 11625 13168 158985 139318 39298 100823 61768 267234 172714 193381 77366 234972 179072 124357 293293 211208 13645 291334 178622 254265 698...
result:
ok
Test #13:
score: 0
Accepted
time: 263ms
memory: 26124kb
input:
300000 37117 223947 199643 280354 274799 172294 226464 27333 43649 32485 130021 84630 70467 44592 112478 126488 133072 64293 271409 15857 288456 210421 139805 140 162685 49229 14096 273871 55693 11924 137750 93654 255246 78666 132904 163741 50059 8408 121274 230817 269075 125691 270537 260948 277126...
output:
YES 206503 54924 171706 215435 52876 212642 198446 234977 46316 63941 59970 124623 175991 223113 284874 265115 120376 41628 297868 116881 239833 109905 259357 147933 128298 9967 37771 262610 279966 283605 121326 229440 29711 201718 37521 71445 185964 82251 278089 72593 95951 79392 102536 284804 2036...
result:
ok
Test #14:
score: 0
Accepted
time: 285ms
memory: 25988kb
input:
300000 268783 101895 27590 114760 14864 171076 137533 59382 133722 236003 277744 187278 189110 80196 260321 229396 293370 59604 66690 46811 188856 113279 158853 279087 234008 145840 62098 148819 90304 135703 264489 61055 1527 291426 228720 253339 128391 282367 230693 36857 134937 283157 178978 28302...
output:
YES 262573 131560 74447 201754 184391 268870 103923 101556 74245 264943 251392 210380 180071 230445 147357 191487 202290 106429 270654 99965 281336 241887 149375 248014 247235 277772 14019 281316 107207 154448 179237 210166 237294 214553 137373 122502 242731 10036 141861 117674 117999 238515 43945 1...
result:
ok
Test #15:
score: 0
Accepted
time: 295ms
memory: 25932kb
input:
300000 150950 267369 289017 3183 121065 253781 250699 196624 166248 1258 62584 164129 74238 205040 69940 242240 206512 45807 237009 152011 106234 113446 262178 6360 11915 293426 240715 210047 155609 91195 5698 108687 52572 64202 259254 131021 23340 3637 101657 75893 50362 114481 46841 259603 92022 2...
output:
YES 242638 102314 120047 8119 269298 54543 172640 298709 5920 45654 236982 296913 41629 12218 117156 75350 19178 291647 213850 178446 107588 262547 167597 55696 29397 6142 230877 144924 116853 255653 76394 223911 295013 263682 211288 243225 44297 17808 10190 54339 263534 182243 137420 1163 290038 29...
result:
ok
Test #16:
score: 0
Accepted
time: 303ms
memory: 27608kb
input:
300000 49709 89567 116527 61741 285831 50661 101522 82524 53092 66068 86222 189736 218043 73160 13162 26534 168441 105087 11975 25881 90532 14377 232905 194513 267892 122922 272020 12435 149258 264534 123074 211569 169040 7735 137914 80789 257276 127051 35078 31990 179149 44365 178698 23293 114696 1...
output:
YES 243933 3505 138365 96473 195183 20163 159960 62679 68422 78190 247305 170071 16877 272651 237230 30122 173457 240509 185347 11178 157880 254426 101052 212915 119702 235537 223194 72916 128518 180441 9603 105260 201637 39874 164310 39195 92734 158243 134980 58487 5560 199438 36022 42374 90005 269...
result:
ok
Test #17:
score: 0
Accepted
time: 292ms
memory: 31368kb
input:
300000 11520 95384 25302 98828 47757 177418 33783 201064 249009 132959 160957 223098 69371 147959 297586 265064 111848 112 54402 243987 221427 176478 78297 103877 283871 164241 278667 280291 165910 63063 263388 174421 236875 249121 49837 32872 185947 118645 298053 206918 282114 120453 169448 108351 ...
output:
YES 45231 137515 204219 160205 90531 74380 202274 282262 29653 271957 16294 259424 257320 72584 278386 73022 179094 30666 295722 190780 246708 7850 275993 109880 100250 273397 44181 188702 225052 221475 283040 113981 16767 224417 154206 6397 42076 118750 139876 193140 138747 282758 105619 259549 150...
result:
ok
Test #18:
score: 0
Accepted
time: 316ms
memory: 35184kb
input:
300000 266316 130154 271618 232285 202160 263507 132088 15648 107605 189613 287651 88616 182956 80933 93644 64472 151741 159119 156651 146038 95404 292422 197240 139293 193081 296605 286792 1138 90636 95542 221620 185379 21658 170349 261710 33666 32379 29518 47764 23367 137414 92197 292446 226026 28...
output:
YES 82153 297150 233178 95032 166284 113363 163086 235423 100907 143086 165769 93871 290092 129724 280803 200655 152734 18075 53143 129336 174543 56348 163997 111763 147387 205865 4670 215701 288542 17764 102159 32383 248795 202734 64403 84005 52778 251809 187099 252074 294452 10886 189085 181943 41...
result:
ok
Test #19:
score: 0
Accepted
time: 139ms
memory: 26480kb
input:
300000 12780 264648 12780 121374 12780 42008 12780 95697 12780 976 12780 177512 12780 106434 12780 278098 12780 140080 12780 110499 12780 295006 12780 235728 12780 299674 12780 116423 12780 279890 12780 244785 12780 180340 12780 197080 12780 103638 12780 7503 12780 151147 12780 87425 12780 247699 12...
output:
NO
result:
ok
Test #20:
score: 0
Accepted
time: 175ms
memory: 28124kb
input:
300000 299736 96862 299736 241034 299736 200539 299736 117184 299736 262455 299736 285421 299736 289066 299736 110126 299736 121907 299736 159583 299736 35052 299736 225040 299736 83339 299736 44763 299736 139926 299736 1418 299736 131518 299736 166271 299736 274471 299736 296220 299736 146978 29973...
output:
YES 129131 288167 299736 96862 241034 200539 117184 262455 285421 289066 110126 121907 159583 35052 225040 83339 44763 139926 1418 131518 166271 274471 296220 146978 201085 161544 162910 109976 249870 44208 22149 66753 287 90379 15531 249789 89351 26074 4544 196109 121259 107632 60995 83160 151863 2...
result:
ok
Test #21:
score: 0
Accepted
time: 173ms
memory: 27928kb
input:
300000 279101 105712 279101 249105 279101 112302 279101 17133 279101 30550 279101 152384 279101 275247 279101 159978 279101 40600 279101 248027 279101 133490 279101 130020 279101 127010 279101 111540 279101 121005 279101 150446 279101 107171 279101 215779 279101 13025 279101 132710 279101 39038 2791...
output:
YES 55042 184540 40365 279101 105712 249105 112302 17133 30550 152384 275247 159978 40600 248027 133490 130020 127010 111540 121005 150446 107171 215779 13025 132710 39038 122982 44159 200125 180086 32840 251507 240864 55779 159975 37848 8418 237512 284840 146723 12038 291415 121661 166956 133006 55...
result:
ok
Test #22:
score: 0
Accepted
time: 0ms
memory: 14948kb
input:
200 107 93 93 144 107 70 93 23 107 162 93 3 107 174 93 26 107 195 93 101 107 126 93 55 107 183 93 74 107 59 93 76 107 118 93 38 107 54 93 29 107 61 93 152 107 125 93 122 107 192 93 85 107 77 93 25 107 133 93 123 107 87 93 172 107 71 93 167 107 60 93 120 107 184 93 68 107 104 93 80 107 95 93 96 107 1...
output:
YES 107 4 93 144 23 3 26 101 55 74 76 38 29 152 122 85 25 123 172 167 120 68 80 96 30 18 47 39 163 12 117 113 15 189 169 168 132 40 73 48 49 150 91 20 6 52 146 180 2 176 5 154 187 155 188 46 1 11 161 75 99 10 27 86 45 115 44 179 102 166 114 109 121 42 139 51 198 34 160 131 175 130 31 65 37 35 116 19...
result:
ok
Test #23:
score: 0
Accepted
time: 0ms
memory: 15040kb
input:
200 12 102 102 116 12 105 102 174 12 133 102 144 12 108 102 13 12 151 102 110 12 91 102 162 12 98 102 38 12 149 102 74 12 47 102 190 12 10 102 175 12 186 102 153 12 85 102 199 12 36 102 29 12 147 102 1 12 152 102 45 12 11 102 84 12 146 102 119 12 179 102 7 12 32 102 53 12 9 102 118 12 141 102 177 12...
output:
YES 146 106 12 102 116 174 144 13 110 162 38 74 190 175 153 172 199 29 1 45 84 119 7 53 118 72 177 70 39 132 34 176 124 197 139 182 68 3 125 33 59 112 49 188 20 195 18 19 27 113 156 193 187 16 37 87 57 173 164 30 148 142 120 181 183 126 111 65 21 64 78 79 159 24 44 166 50 169 122 46 95 123 83 100 17...
result:
ok
Test #24:
score: 0
Accepted
time: 172ms
memory: 26636kb
input:
300000 90531 114135 114135 178759 90531 123121 114135 161955 90531 120679 114135 205637 90531 97753 114135 97745 90531 46366 114135 13177 90531 232931 114135 139366 90531 180616 114135 72520 90531 287031 114135 14029 90531 45741 114135 288828 90531 111901 114135 63091 90531 83073 114135 77690 90531 ...
output:
YES 114135 2 90531 123121 120679 97753 46366 232931 180616 287031 45741 111901 83073 247170 14493 72369 271218 221806 205954 47425 26334 97031 120855 131246 83178 272257 287596 68351 173955 212727 64184 201341 94602 236280 269867 60896 176484 46621 264385 293375 170854 110590 22910 153799 167598 351...
result:
ok
Test #25:
score: 0
Accepted
time: 173ms
memory: 26504kb
input:
300000 141727 171472 171472 62588 141727 30250 171472 267034 141727 37741 171472 141522 141727 159683 171472 256922 141727 241118 171472 153803 141727 18425 171472 172334 141727 124007 171472 13772 141727 10366 171472 213390 141727 173862 171472 77299 141727 218798 171472 122799 141727 34360 171472 ...
output:
YES 218307 50284 141727 171472 62588 267034 141522 256922 153803 172334 13772 213390 77299 122799 228288 297727 46400 83399 56700 130086 268084 129659 256509 45960 285192 138897 22215 79218 16213 38825 266545 75929 211304 255187 66297 248292 156232 240543 243770 12543 143273 295609 136997 54447 2371...
result:
ok
Test #26:
score: 0
Accepted
time: 4ms
memory: 14988kb
input:
10 7 9 3 8 5 3 4 5 9 1 2 6 1 10 8 7 6 4
output:
YES 6 2 4 5 3 8 7 9 1 10
result:
ok
Test #27:
score: 0
Accepted
time: 75ms
memory: 23548kb
input:
100000 4758 24995 70871 48101 57182 14922 78150 88326 5931 79858 4301 85469 17851 58413 60571 32187 75364 94152 24329 33975 99469 3833 26334 70008 78549 7447 9947 73063 18450 61713 24760 56646 9992 98945 34938 175 81746 41108 46227 77863 94891 10911 39706 67754 73219 55460 81410 3578 43031 14828 380...
output:
YES 11975 37491 40438 57703 547 96982 17898 4868 63867 73960 68945 53473 93550 18282 53093 20828 37763 34231 97314 39110 79986 63129 20152 16206 44247 53011 21025 77458 82703 65353 92222 53402 45393 38031 8815 65700 99095 94410 49857 33273 20531 58166 48618 42217 29160 18121 54389 78596 76276 47546 ...
result:
ok
Test #28:
score: 0
Accepted
time: 4ms
memory: 14768kb
input:
6 5 3 3 6 5 2 3 4 5 1
output:
YES 3 4 5 2 1 6
result:
ok
Test #29:
score: 0
Accepted
time: 0ms
memory: 14820kb
input:
8 5 3 3 2 5 7 3 8 5 4 3 6 5 1
output:
YES 3 2 5 7 4 1 8 6
result:
ok
Test #30:
score: 0
Accepted
time: 0ms
memory: 14760kb
input:
8 2 1 1 6 2 8 1 4 2 5 1 3 2 7
output:
YES 2 5 1 6 4 3 8 7
result:
ok
Test #31:
score: 0
Accepted
time: 2ms
memory: 14848kb
input:
8 5 8 8 3 5 7 8 6 5 4 8 2 5 1
output:
YES 8 2 5 7 4 1 3 6
result:
ok
Test #32:
score: 0
Accepted
time: 4ms
memory: 14844kb
input:
8 2 4 4 3 2 8 4 6 2 5 4 7 2 1
output:
YES 4 3 2 8 5 1 6 7
result:
ok
Test #33:
score: 0
Accepted
time: 0ms
memory: 14980kb
input:
8 7 6 6 5 7 8 6 1 7 3 6 4 7 2
output:
YES 7 2 6 5 1 4 8 3
result:
ok
Test #34:
score: 0
Accepted
time: 0ms
memory: 14824kb
input:
16 10 1 1 3 10 4 1 2 10 14 1 7 10 9 1 13 10 6 1 5 10 12 1 15 10 8 1 11 10 16
output:
YES 10 4 1 3 2 7 13 5 15 11 14 9 6 12 8 16
result:
ok
Test #35:
score: 0
Accepted
time: 2ms
memory: 14988kb
input:
128 53 111 111 61 53 48 111 121 53 32 111 93 53 97 111 19 53 35 111 105 53 8 111 101 53 44 111 94 53 58 111 80 53 16 111 79 53 96 111 88 53 90 111 98 53 55 111 17 53 69 111 40 53 84 111 59 53 126 111 71 53 36 111 47 53 14 111 49 53 77 111 128 53 22 111 20 53 10 111 54 53 95 111 119 53 12 111 64 53 2...
output:
YES 111 3 53 48 32 97 35 8 44 58 16 96 90 55 69 84 126 36 14 77 22 10 95 12 27 106 124 23 31 67 73 11 102 45 100 82 89 52 24 87 1 2 91 62 41 112 110 125 65 5 57 81 86 21 43 25 75 50 37 30 74 99 76 28 103 7 61 121 93 19 105 101 94 80 79 88 98 17 40 59 71 47 49 128 20 54 119 64 56 18 118 104 83 68 70 ...
result:
ok
Test #36:
score: 0
Accepted
time: 199ms
memory: 25864kb
input:
300000 250443 449 250443 22884 250443 144955 250443 124134 250443 166560 250443 196513 250443 53759 250443 191771 250443 152495 250443 146696 250443 33720 250443 74643 250443 148572 250443 259831 250443 152960 250443 28807 250443 274820 250443 105639 250443 159610 250443 147117 250443 117152 250443 ...
output:
YES 226487 239079 95545 53442 48223 3420 223966 250443 449 73683 145296 22884 144955 124134 103063 166560 196513 53759 191771 168099 152495 146696 33720 2155 74643 172425 148572 259831 152960 28807 274820 105639 122390 159610 147117 117152 149064 232139 105083 254735 259777 223897 68534 296449 12522...
result:
ok
Test #37:
score: 0
Accepted
time: 0ms
memory: 14868kb
input:
4 1 2 3 4 1 4
output:
YES 4 3 1 2
result:
ok
Test #38:
score: 0
Accepted
time: 0ms
memory: 14840kb
input:
4 1 3 1 4 3 2
output:
YES 3 2 1 4
result:
ok
Test #39:
score: 0
Accepted
time: 4ms
memory: 14876kb
input:
4 1 4 2 3 2 4
output:
YES 2 3 4 1
result:
ok
Test #40:
score: 0
Accepted
time: 0ms
memory: 14748kb
input:
4 2 4 1 2 4 3
output:
YES 4 3 2 1
result:
ok
Test #41:
score: 0
Accepted
time: 0ms
memory: 14828kb
input:
4 4 3 4 2 1 2
output:
YES 4 3 2 1
result:
ok
Test #42:
score: 0
Accepted
time: 0ms
memory: 14844kb
input:
4 2 3 4 2 3 1
output:
YES 2 4 3 1
result:
ok
Test #43:
score: 0
Accepted
time: 0ms
memory: 14784kb
input:
4 1 3 2 1 4 2
output:
YES 2 4 1 3
result:
ok
Test #44:
score: 0
Accepted
time: 4ms
memory: 14776kb
input:
4 3 2 1 3 4 2
output:
YES 2 4 3 1
result:
ok
Test #45:
score: 0
Accepted
time: 2ms
memory: 14884kb
input:
4 4 1 4 3 1 2
output:
YES 4 3 1 2
result:
ok
Test #46:
score: 0
Accepted
time: 3ms
memory: 14936kb
input:
5 2 3 5 1 2 4 5 3
output:
YES 2 4 3 5 1
result:
ok
Test #47:
score: 0
Accepted
time: 4ms
memory: 14900kb
input:
6 2 5 5 1 3 6 4 6 3 1
output:
YES 6 4 3 1 5 2
result:
ok
Test #48:
score: 0
Accepted
time: 0ms
memory: 14868kb
input:
7 6 4 3 7 2 6 2 5 4 1 5 7
output:
YES 7 3 5 2 6 4 1
result:
ok
Test #49:
score: 0
Accepted
time: 0ms
memory: 14752kb
input:
4 4 2 2 3 4 1
output:
YES 2 3 4 1
result:
ok
Test #50:
score: 0
Accepted
time: 0ms
memory: 14844kb
input:
4 1 4 1 2 3 2
output:
YES 2 3 1 4
result:
ok
Test #51:
score: 0
Accepted
time: 0ms
memory: 14816kb
input:
4 1 2 1 4 2 3
output:
YES 2 3 1 4
result:
ok
Test #52:
score: 0
Accepted
time: 0ms
memory: 14748kb
input:
4 1 3 1 4 3 2
output:
YES 3 2 1 4
result:
ok
Test #53:
score: 0
Accepted
time: 0ms
memory: 14948kb
input:
6 1 2 1 3 1 4 2 5 2 6
output:
YES 2 5 1 3 4 6
result:
ok
Test #54:
score: 0
Accepted
time: 0ms
memory: 14808kb
input:
6 1 6 6 5 5 3 4 5 2 6
output:
YES 5 3 6 1 2 4
result:
ok
Test #55:
score: 0
Accepted
time: 0ms
memory: 14744kb
input:
6 2 4 4 6 1 3 5 3 4 1
output:
YES 4 2 6 1 3 5
result:
ok
Test #56:
score: 0
Accepted
time: 2ms
memory: 14912kb
input:
6 3 4 4 1 2 4 6 3 3 5
output:
YES 3 5 4 1 2 6
result:
ok
Test #57:
score: 0
Accepted
time: 2ms
memory: 14948kb
input:
6 1 2 1 3 5 6 5 4 5 1
output:
YES 5 4 6 1 2 3
result:
ok
Test #58:
score: 0
Accepted
time: 4ms
memory: 14828kb
input:
6 6 1 6 2 3 4 5 3 6 3
output:
YES 3 4 5 6 1 2
result:
ok