QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#767122 | #9607. 熟练 | ZhaoZiLong | 45 | 505ms | 31912kb | C++20 | 2.9kb | 2024-11-20 19:53:12 | 2024-11-20 19:53:13 |
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
Subtask #1:
score: 3
Accepted
Test #1:
score: 3
Accepted
time: 31ms
memory: 11632kb
input:
1 100000 1 2 1 1 1 1 3 5 1 2 2 3 2 1 2 3 1 1 1 1 3 3 1 3 1 1 1 1 1 1 4 4 1 2 2 3 3 4 3 3 2 1 3 3 4 2 5 3 1 2 1 3 1 4 2 5 1 1 3 3 3 1 1 5 1 1 1 1 1 1 1 1 1 1 2 5 1 2 2 1 1 2 1 2 1 2 1 2 2 2 1 2 2 2 2 2 4 2 1 2 1 3 1 4 4 4 2 3 2 3 1 2 1 2 1 1 1 1 1 4 1 1 1 1 1 1 1 1 5 3 1 2 2 3 3 4 4 5 3 4 4 5 5 2 2 1...
output:
2 1 2 3 1 2 2 3 1 3 1 2 3 3 1 1 3 2 2 1 1 2 5 1 2 3 4 5 5 1 2 3 4 5 2 1 2 1 1 1 3 1 2 3 4 1 2 3 4 3 2 3 1 1 1 2 1 2 4 1 2 3 4 3 1 2 1 3 3 1 2 1 3 1 1 2 2 1 2 1 2 4 1 2 3 4 3 3 1 2 1 4 1 2 3 4 1 1 1 4 1 2 3 4 1 1 5 1 2 3 4 5 1 1 1 5 1 2 3 4 5 2 1 2 1 3 1 2 1 3 3 1 2 3 ...
result:
ok ok
Subtask #2:
score: 0
Runtime Error
Dependency #1:
100%
Accepted
Test #2:
score: 0
Runtime Error
input:
2 1005 489417 5 1 2 1 3 2 4 2 5 3 6 3 7 4 8 4 9 5 10 5 11 6 12 6 13 7 14 7 15 8 16 8 17 9 18 9 19 10 20 10 21 11 22 11 23 12 24 12 25 13 26 13 27 14 28 14 29 15 30 15 31 16 32 16 33 17 34 17 35 18 36 18 37 19 38 19 39 20 40 20 41 21 42 21 43 22 44 22 45 23 46 23 47 24 48 24 49 25 50 25 51 26 52 26 5...
output:
result:
Subtask #3:
score: 0
Runtime Error
Test #11:
score: 0
Runtime Error
input:
3 1769 481318 428631 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50...
output:
result:
Subtask #4:
score: 20
Accepted
Test #17:
score: 20
Accepted
time: 6ms
memory: 11880kb
input:
4 37 923 917 1 2 1 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 1 12 10 13 4 14 11 15 9 16 8 17 5 18 18 19 2 20 13 21 12 22 14 23 19 24 3 25 16 26 15 27 22 28 28 29 21 30 6 31 31 32 23 33 1 34 17 35 30 36 26 37 37 38 34 39 20 40 40 41 39 42 41 43 38 44 24 45 33 46 42 47 25 48 45 49 29 50 36 51 48 52 43 53 51...
output:
839 1 1 2 2 3 4 5 6 7 8 1 9 10 11 12 13 14 15 16 17 18 1 19 20 1 21 22 23 24 2 25 26 27 28 2 29 1 30 1 31 32 33 34 35 36 37 38 7 39 40 41 42 43 44 45 46 47 8 48 49 50 51 52 53 54 55 1 56 57 1 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 2 1 78 79 80 81 82 83 84 85 86 8 87 88 89 90 91 ...
result:
ok ok
Test #18:
score: 20
Accepted
time: 7ms
memory: 11848kb
input:
4 26 910 955 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 51 5...
output:
417 153 83 233 397 309 69 58 49 90 113 122 171 283 88 55 197 11 5 215 21 210 49 154 3 117 134 143 173 324 8 158 36 198 10 167 318 210 367 199 22 65 49 35 252 13 178 44 33 8 241 60 229 29 242 8 108 146 18 220 29 204 28 128 97 113 31 6 280 34 49 352 24 8 1 398 50 358 174 123 155 56 315 17 258 13 268 2...
result:
ok ok
Test #19:
score: 20
Accepted
time: 3ms
memory: 11928kb
input:
4 27 932 945 1 2 1 3 2 4 2 5 3 6 3 7 4 8 4 9 5 10 5 11 6 12 6 13 7 14 7 15 8 16 8 17 9 18 9 19 10 20 10 21 11 22 11 23 12 24 12 25 13 26 13 27 14 28 14 29 15 30 15 31 16 32 16 33 17 34 17 35 18 36 18 37 19 38 19 39 20 40 20 41 21 42 21 43 22 44 22 45 23 46 23 47 24 48 24 49 25 50 25 51 26 52 26 53 2...
output:
161 1 2 3 3 48 4 1 2 1 1 2 5 1 2 6 127 5 4 3 7 8 1 9 135 19 10 3 5 1 11 6 12 13 136 5 9 14 7 16 4 2 8 3 127 15 10 7 6 2 20 21 9 1 9 2 128 22 4 3 10 16 4 5 6 17 7 2 3 3 127 8 23 2 2 9 11 18 1 12 13 24 14 8 5 128 10 6 15 1 19 10 11 16 17 18 7 7 20 1 2 8 25 12 62 1 26 1 4 27 28 119 13 19 29 20 127 128 ...
result:
ok ok
Test #20:
score: 20
Accepted
time: 3ms
memory: 14036kb
input:
4 27 915 930 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 51 5...
output:
473 270 11 22 133 237 69 254 56 170 276 288 22 241 272 18 293 307 353 419 98 158 169 77 272 382 172 67 337 38 130 334 113 275 63 375 16 135 115 63 40 383 326 209 201 117 297 130 54 145 25 11 95 123 324 8 80 196 25 26 131 2 250 198 226 96 363 315 237 210 192 250 12 125 379 401 341 211 146 19 52 17 28...
result:
ok ok
Test #21:
score: 20
Accepted
time: 7ms
memory: 14060kb
input:
4 20 966 940 1 2 2 3 1 4 4 5 5 6 2 7 2 8 6 9 2 10 10 11 3 12 4 13 6 14 11 15 2 16 1 17 13 18 15 19 16 20 16 21 20 22 5 23 6 24 18 25 21 26 18 27 18 28 7 29 25 30 29 31 21 32 3 33 4 34 32 35 16 36 14 37 15 38 16 39 17 40 4 41 7 42 22 43 1 44 33 45 31 46 37 47 15 48 5 49 30 50 43 51 16 52 47 53 13 54 ...
output:
196 28 1 46 105 2 124 3 4 5 6 137 30 7 138 142 37 5 8 9 143 144 10 2 11 145 12 13 1 14 146 147 15 1 16 17 18 19 20 10 21 22 3 23 2 148 24 149 25 150 26 27 28 151 5 29 4 30 31 152 153 32 1 33 154 46 34 35 36 37 3 155 156 48 38 39 56 40 41 42 43 44 45 46 47 48 157 158 159 160 49 50 161 51 52 162 75 5 ...
result:
ok ok
Test #22:
score: 20
Accepted
time: 3ms
memory: 11920kb
input:
4 28 920 959 1 2 2 3 1 4 3 5 2 6 4 7 6 8 3 9 4 10 6 11 11 12 8 13 3 14 4 15 8 16 13 17 3 18 17 19 11 20 14 21 7 22 19 23 7 24 12 25 3 26 12 27 22 28 9 29 15 30 17 31 14 32 8 33 2 34 7 35 12 36 13 37 22 38 25 39 20 40 37 41 11 42 29 43 17 44 23 45 36 46 7 47 27 48 24 49 30 50 28 51 17 52 26 53 46 54 ...
output:
216 1 4 2 1 7 3 4 2 99 101 3 4 104 5 6 7 105 8 9 10 11 12 13 14 9 108 2 109 4 15 10 2 11 110 112 16 3 5 1 17 18 62 125 114 2 126 19 5 115 117 20 1 21 2 1 22 6 14 23 3 24 25 26 27 8 28 124 29 5 6 125 30 31 32 33 34 35 36 37 38 39 40 126 41 127 128 129 42 43 9 15 4 130 44 45 46 8 19 20 1 7 47 48 127 2...
result:
ok ok
Test #23:
score: 20
Accepted
time: 6ms
memory: 11968kb
input:
4 24 935 984 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 51 5...
output:
175 93 84 27 39 11 7 8 48 46 3 30 83 75 168 119 107 10 55 130 53 82 22 62 96 99 43 59 85 20 55 45 3 124 33 65 64 123 30 148 65 135 140 23 77 117 159 85 21 138 104 103 126 52 15 20 37 86 120 88 48 127 1 136 29 54 68 56 77 153 30 137 108 6 78 144 16 127 15 36 13 10 23 111 86 3 98 147 11 102 71 6 95 3 ...
result:
ok ok
Test #24:
score: 20
Accepted
time: 3ms
memory: 9916kb
input:
4 31 919 917 1 2 1 3 2 4 2 5 3 6 3 7 4 8 4 9 5 10 5 11 6 12 6 13 7 14 7 15 8 16 8 17 9 18 9 19 10 20 10 21 11 22 11 23 12 24 12 25 13 26 13 27 14 28 14 29 15 30 15 31 16 32 16 33 17 34 17 35 18 36 18 37 19 38 19 39 20 40 20 41 21 42 21 43 22 44 22 45 23 46 23 47 24 48 24 49 25 50 25 51 26 52 26 53 2...
output:
588 89 467 468 469 467 470 1 2 3 1 4 5 6 468 7 2 8 2 471 9 10 472 11 12 13 14 473 15 16 4 469 17 470 471 18 19 472 474 20 21 4 5 1 22 23 24 25 473 1 26 27 28 29 30 31 32 474 33 475 1 3 476 34 477 478 35 475 6 36 479 37 38 39 480 40 41 42 43 44 45 46 47 481 48 476 49 5 477 50 51 7 482 483 484 478 5 3...
result:
ok ok
Test #25:
score: 20
Accepted
time: 7ms
memory: 12044kb
input:
4 22 986 926 1 2 2 3 1 4 2 5 4 6 6 7 3 8 5 9 7 10 4 11 3 12 4 13 7 14 5 15 3 16 8 17 1 18 8 19 3 20 1 21 5 22 2 23 4 24 8 25 4 26 3 27 2 28 1 29 4 30 2 31 2 32 5 33 3 34 6 35 5 36 5 37 6 38 1 39 8 40 5 41 6 42 3 43 8 44 1 45 8 46 6 47 8 48 4 49 6 50 3 51 8 52 7 53 4 54 5 55 6 56 5 57 4 58 8 59 2 60 ...
output:
123 1 1 1 2 2 1 3 2 1 2 2 1 3 4 4 2 3 4 3 5 4 5 2 3 5 4 5 6 6 3 6 2 3 4 4 7 7 6 7 3 8 7 5 9 8 9 8 5 5 8 10 9 6 10 11 7 6 12 9 13 8 6 7 10 14 8 7 15 4 11 11 5 12 6 10 11 7 9 9 8 13 16 17 12 13 10 14 14 15 12 13 14 11 15 12 16 15 9 10 13 16 18 14 17 17 10 16 11 18 8 9 12 18 13 19 15 14 20 17 18 21 19 ...
result:
ok ok
Test #26:
score: 20
Accepted
time: 6ms
memory: 10008kb
input:
4 22 931 950 1 2 1 3 2 4 3 5 3 6 2 7 6 8 3 9 7 10 7 11 8 12 5 13 3 14 4 15 2 16 3 17 8 18 1 19 3 20 5 21 5 22 6 23 8 24 3 25 1 26 8 27 8 28 8 29 5 30 6 31 4 32 6 33 3 34 8 35 6 36 6 37 7 38 2 39 3 40 8 41 8 42 3 43 8 44 5 45 6 46 7 47 2 48 2 49 1 50 4 51 7 52 7 53 6 54 3 55 3 56 5 57 1 58 5 59 7 60 ...
output:
648 1 3 2 3 4 5 8 2 1 6 7 8 5 9 10 10 11 11 12 30 13 14 15 16 2 33 3 17 18 19 15 20 21 5 2 22 23 18 24 25 26 27 28 29 30 31 32 33 34 35 4 36 23 3 37 38 27 39 38 40 7 28 41 42 43 5 44 45 68 46 6 75 47 31 4 32 48 49 9 50 51 52 76 53 46 77 48 54 87 55 56 1 93 50 57 2 58 94 59 100 55 109 111 60 61 62 63...
result:
ok ok
Test #27:
score: 20
Accepted
time: 3ms
memory: 12032kb
input:
4 24 990 970 1 2 2 3 3 4 4 5 4 6 3 7 5 8 6 9 2 10 2 11 5 12 3 13 4 14 6 15 9 16 7 17 3 18 17 19 10 20 7 21 12 22 2 23 13 24 23 25 20 26 26 27 20 28 11 29 16 30 16 31 16 32 1 33 31 34 26 35 24 36 24 37 13 38 12 39 15 40 29 41 33 42 21 43 6 44 44 45 10 46 29 47 24 48 24 49 30 50 6 51 12 52 21 53 26 54...
output:
675 1 1 10 12 88 89 13 18 20 22 90 2 3 26 1 31 9 39 47 91 92 3 93 94 5 2 7 1 95 96 97 56 98 59 99 100 101 65 67 102 9 68 72 103 104 74 2 105 106 75 107 108 109 79 85 13 1 88 90 110 101 14 111 112 113 114 115 15 2 6 116 102 3 4 117 103 118 119 5 120 19 21 136 147 149 5 6 153 121 162 163 122 180 123 2...
result:
ok ok
Test #28:
score: 20
Accepted
time: 7ms
memory: 11968kb
input:
4 22 971 961 1 2 2 3 1 4 3 5 4 6 6 7 2 8 3 9 2 10 10 11 8 12 11 13 11 14 9 15 9 16 8 17 8 18 10 19 10 20 20 21 13 22 10 23 12 24 12 25 23 26 4 27 18 28 23 29 4 30 5 31 19 32 7 33 20 34 7 35 4 36 36 37 28 38 14 39 15 40 14 41 34 42 19 43 33 44 3 45 33 46 35 47 31 48 9 49 42 50 8 51 36 52 27 53 44 54 ...
output:
377 13 36 1 2 2 2 3 41 4 1 3 51 5 3 1 56 5 6 7 8 9 4 10 11 12 1 13 79 14 98 2 15 3 16 17 18 19 6 8 20 130 21 22 23 24 25 26 6 27 1 190 207 9 208 10 28 29 30 212 213 6 31 216 224 55 32 1 33 227 233 1 235 34 243 244 245 11 35 36 37 246 38 15 1 21 39 40 247 9 3 248 41 64 42 43 249 44 4 45 250 46 17 47 ...
result:
ok ok
Test #29:
score: 20
Accepted
time: 6ms
memory: 13936kb
input:
4 25 994 999 1 2 1 3 1 4 1 5 1 6 1 7 1 8 8 9 3 10 7 11 9 12 1 13 12 14 11 15 15 16 5 17 16 18 13 19 6 20 4 21 17 22 19 23 2 24 10 25 23 26 20 27 24 28 27 29 18 30 22 31 31 32 32 33 14 34 34 35 26 36 36 37 29 38 21 39 30 40 39 41 28 42 35 43 41 44 25 45 33 46 44 47 42 48 38 49 40 50 50 51 46 52 45 53...
output:
261 2 1 2 3 4 5 6 7 8 9 10 10 11 12 13 14 15 16 17 18 19 20 21 1 22 23 9 24 9 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 2 3 55 56 57 58 59 2 60 61 62 63 64 65 66 67 3 68 69 70 71 2 1 72 73 74 75 76 77 78 79 80 6 81 82 83 84 85 86 87 88 89 90 9 91 92 93...
result:
ok ok
Test #30:
score: 20
Accepted
time: 5ms
memory: 9896kb
input:
4 31 943 994 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 51 5...
output:
34 12 1 9 7 5 4 6 17 5 9 26 15 26 1 17 9 5 9 10 3 10 6 15 4 14 22 12 19 7 1 2 7 10 8 2 6 9 3 16 12 2 5 4 13 26 31 10 14 10 26 4 9 13 9 20 9 10 12 2 17 17 26 9 16 3 2 25 8 7 2 32 19 6 12 11 15 8 7 3 20 8 4 11 7 15 4 14 8 18 2 14 6 5 1 1 3 9 10 4 18 1 6 4 18 3 7 7 22 18 1 5 13 2 2 1 20 11 17 5 4 7 15 ...
result:
ok ok
Test #31:
score: 20
Accepted
time: 7ms
memory: 13996kb
input:
4 27 981 972 1 2 1 3 2 4 3 5 5 6 6 7 7 8 1 9 9 10 4 11 11 12 8 13 13 14 14 15 15 16 12 17 16 18 17 19 10 20 20 21 19 22 18 23 21 24 22 25 25 26 23 27 24 28 27 29 29 30 30 31 31 32 28 33 32 34 33 35 35 36 26 37 34 38 38 39 39 40 36 41 41 42 40 43 42 44 37 45 43 46 46 47 44 48 45 49 49 50 50 51 47 52 ...
output:
19 1 2 3 4 5 6 7 8 17 2 3 5 1 5 1 1 1 6 2 1 6 6 7 5 2 1 1 2 1 1 1 8 1 1 1 1 2 1 2 1 1 5 4 1 1 1 2 10 5 4 5 1 2 1 2 2 1 3 1 1 1 6 6 4 1 2 1 6 9 1 1 8 1 2 2 1 3 1 5 8 1 1 10 1 6 1 11 2 3 3 1 1 1 5 2 1 1 6 7 1 9 5 1 9 3 3 1 3 1 9 1 3 4 1 3 1 3 5 2 1 1 5 1 1 6 3 1 9 1 1 14 2 6 16 3 2 5 4 1 4 5 1 1 4 3 2...
result:
ok ok
Test #32:
score: 20
Accepted
time: 3ms
memory: 11968kb
input:
4 27 941 912 1 2 1 3 2 4 3 5 1 6 5 7 1 8 8 9 6 10 1 11 2 12 10 13 3 14 12 15 7 16 1 17 13 18 12 19 6 20 13 21 14 22 16 23 1 24 11 25 16 26 9 27 4 28 1 29 2 30 2 31 4 32 14 33 7 34 7 35 5 36 7 37 7 38 15 39 1 40 5 41 5 42 11 43 7 44 15 45 17 46 3 47 11 48 5 49 13 50 4 51 14 52 6 53 6 54 8 55 2 56 1 5...
output:
150 1 1 2 2 2 3 1 4 3 4 3 1 5 4 3 6 2 7 4 5 1 2 6 4 2 7 8 8 9 5 10 9 2 6 11 3 5 3 12 2 2 4 10 6 13 6 1 10 1 1 11 4 1 6 5 6 7 8 4 7 7 8 11 9 9 10 3 14 10 12 8 11 3 9 9 10 13 5 13 3 11 14 15 16 12 2 15 12 13 6 11 12 4 14 17 6 17 18 13 16 7 14 14 13 15 14 8 15 16 16 17 1 18 17 18 17 19 7 19 18 20 20 19...
result:
ok ok
Subtask #5:
score: 22
Accepted
Dependency #4:
100%
Accepted
Test #33:
score: 22
Accepted
time: 201ms
memory: 23464kb
input:
5 496 94286 94269 1 2 1 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 1 11 9 12 4 13 3 14 13 15 1 16 5 17 16 18 15 19 18 20 2 21 10 22 12 23 23 24 14 25 19 26 20 27 26 28 8 29 29 30 27 31 21 32 25 33 28 34 22 35 30 36 17 37 32 38 33 39 7 40 38 41 37 42 39 43 11 44 44 45 35 46 40 47 41 48 43 49 24 50 34 51 45 52 47...
output:
27238 1 2 3 4 124 54 5 139 6 7 8 9 10 11 12 13 14 15 16 97 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 37 40 41 123 42 43 44 45 46 91 47 48 44 49 50 51 52 53 54 55 56 57 58 59 60 61 62 40 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 ...
result:
ok ok
Test #34:
score: 22
Accepted
time: 347ms
memory: 21280kb
input:
5 102 87302 98915 1 2 2 3 3 4 4 5 1 6 2 7 3 8 1 9 7 10 3 11 9 12 5 13 2 14 13 15 3 16 9 17 7 18 13 19 19 20 16 21 4 22 20 23 14 24 18 25 17 26 26 27 7 28 4 29 3 30 28 31 16 32 32 33 5 34 13 35 17 36 10 37 19 38 14 39 22 40 22 41 36 42 25 43 43 44 12 45 6 46 33 47 24 48 38 49 8 50 31 51 26 52 47 53 2...
output:
43611 3 1 2 3 23 34 4 135 5 5 235 264 6 285 1 3 292 313 373 7 384 4 8 5 389 6 9 415 1 436 439 10 8 11 450 11 493 12 12 496 13 2 499 547 14 17 14 15 559 6 16 578 598 605 17 18 1 18 626 19 20 21 22 1 651 656 665 19 679 4 2 23 24 7 20 25 1 26 9 692 10 693 21 27 28 13 29 702 758 783 827 5 6 30 15 16 31 ...
result:
ok ok
Test #35:
score: 22
Accepted
time: 505ms
memory: 21076kb
input:
5 465 95072 88256 1 2 1 3 2 4 2 5 3 6 3 7 4 8 4 9 5 10 5 11 6 12 6 13 7 14 7 15 8 16 8 17 9 18 9 19 10 20 10 21 11 22 11 23 12 24 12 25 13 26 13 27 14 28 14 29 15 30 15 31 16 32 16 33 17 34 17 35 18 36 18 37 19 38 19 39 20 40 20 41 21 42 21 43 22 44 22 45 23 46 23 47 24 48 24 49 25 50 25 51 26 52 26...
output:
58693 1 24500 2 3 35913 39857 39857 2 4 5 39858 6 7 8 39859 39860 9 10 11 2 12 3 1 5 39861 13 14 15 39858 39862 16 17 18 19 20 5 6 21 9 3 39863 39864 39865 22 23 24 1 25 39866 26 39859 39867 27 28 29 30 39868 39869 3 8 31 6 7 32 39870 39871 1 33 34 39872 1 9 35 36 37 38 39 5 40 41 39873 11 4 39860 4...
result:
ok ok
Test #36:
score: 22
Accepted
time: 81ms
memory: 13084kb
input:
5 911 9670 12225 1 2 1 3 1 4 1 5 1 6 1 7 1 8 1 9 1 10 8 11 6 12 5 13 4 14 7 15 9 16 16 17 11 18 1 19 14 20 15 21 13 22 3 23 20 24 12 25 24 26 26 27 23 28 18 29 27 30 22 31 2 32 19 33 32 34 25 35 34 36 29 37 10 38 28 39 33 40 30 41 38 42 17 43 41 44 36 45 37 46 45 47 40 48 44 49 48 50 50 51 51 52 49 ...
output:
11000 1 2 3 4 9 5 6 3 7 8 9 10 11 12 26 13 14 17 15 20 16 17 18 19 20 21 22 23 24 25 26 38 27 28 4 29 30 31 32 67 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 4 58 51 59 60 61 62 21 63 64 65 66 67 68 69 70 71 38 72 73 74 75 76 77 78 79 80 81 82 83 84 72 85 86 87 88 89 9...
result:
ok ok
Test #37:
score: 22
Accepted
time: 86ms
memory: 17116kb
input:
5 1077 7078 10459 1 2 1 3 3 4 2 5 3 6 4 7 7 8 3 9 4 10 7 11 9 12 1 13 2 14 8 15 6 16 5 17 5 18 11 19 6 20 14 21 8 22 11 23 12 24 15 25 10 26 10 27 7 28 2 29 7 30 1 31 14 32 7 33 1 34 13 35 11 36 5 37 11 38 8 39 3 40 14 41 3 42 7 43 14 44 6 45 11 46 8 47 13 48 9 49 6 50 4 51 10 52 2 53 12 54 14 55 10...
output:
3386 1 2 5 3 4 5 6 6 7 8 16 20 21 30 1 9 10 1 11 60 12 64 13 14 1 66 2 15 83 16 17 18 1 103 19 104 107 20 21 22 109 3 23 24 25 26 3 110 27 28 29 7 30 31 113 120 32 33 34 125 1 6 35 36 37 38 39 40 154 41 42 7 158 172 43 188 198 44 211 45 46 8 4 47 48 6 5 49 50 51 215 218 52 220 222 53 54 7 9 232 8 55...
result:
ok ok
Test #38:
score: 22
Accepted
time: 118ms
memory: 14432kb
input:
5 942 12731 14938 1 2 2 3 3 4 3 5 2 6 1 7 2 8 4 9 4 10 7 11 7 12 4 13 8 14 6 15 4 16 2 17 10 18 4 19 9 20 3 21 17 22 14 23 6 24 20 25 2 26 3 27 22 28 7 29 15 30 27 31 5 32 19 33 6 34 31 35 11 36 33 37 21 38 10 39 34 40 6 41 20 42 19 43 22 44 27 45 41 46 27 47 34 48 36 49 49 50 26 51 47 52 25 53 35 5...
output:
1051 2 14 6 1 1 10 34 2 3 54 73 97 2 4 4 106 131 133 137 7 5 10 150 169 11 198 12 201 6 2 7 206 7 209 212 8 214 258 9 13 3 10 263 14 11 10 309 12 11 13 13 316 14 17 3 1 2 2 1 1 15 1 15 3 1 16 2 1 16 5 6 8 9 7 1 2 3 14 2 5 15 15 5 3 17 1 6 3 1 329 8 12 16 6 17 17 3 15 18 18 16 5 1 13 4 4 17 3 6 7 5 1...
result:
ok ok
Test #39:
score: 22
Accepted
time: 93ms
memory: 12500kb
input:
5 147 1196 1056 1 2 2 3 2 4 3 5 3 6 5 7 3 8 2 9 3 10 10 11 2 12 3 13 12 14 4 15 4 16 3 17 6 18 6 19 10 20 3 21 9 22 8 23 2 24 2 25 6 26 1 27 4 28 3 29 1 30 11 31 8 32 5 33 5 34 7 35 3 36 9 37 1 38 9 39 6 40 4 41 7 42 5 43 4 44 12 45 2 46 8 47 5 48 8 49 6 50 9 51 11 52 5 53 6 54 2 55 9 56 8 57 10 58 ...
output:
451 1 5 1 2 3 2 15 36 3 3 38 4 51 5 67 4 6 83 7 1 8 5 9 85 10 6 11 7 12 13 88 14 90 95 123 8 15 16 131 17 18 19 20 21 134 22 23 24 9 157 25 175 10 184 8 26 27 3 191 28 192 1 11 2 12 2 193 29 30 31 32 13 14 15 16 17 33 34 5 35 36 18 19 37 194 195 38 20 196 197 3 1 198 21 22 39 23 40 199 41 24 42 43 1...
result:
ok ok
Test #40:
score: 22
Accepted
time: 87ms
memory: 12460kb
input:
5 123 1403 768 1 2 1 3 3 4 1 5 1 6 6 7 2 8 8 9 1 10 3 11 2 12 5 13 5 14 2 15 8 16 10 17 6 18 7 19 8 20 10 21 10 22 10 23 6 24 4 25 4 26 7 27 3 28 3 29 8 30 9 31 4 32 4 33 10 34 8 35 6 36 2 37 3 38 5 39 9 40 2 41 1 42 3 43 1 44 9 45 7 46 2 47 3 48 2 49 3 50 8 51 9 52 5 53 10 54 3 55 3 56 1 57 5 58 2 ...
output:
118 1 1 2 3 2 4 5 6 7 8 9 3 10 11 12 13 14 15 16 1 7 17 2 18 19 20 21 22 23 24 25 26 4 27 28 29 30 31 32 33 34 35 36 37 6 9 38 1 1 1 1 2 7 10 39 1 40 2 3 41 4 5 10 2 4 5 12 42 3 15 11 4 3 43 12 6 17 44 3 5 6 14 3 16 7 45 5 7 4 5 17 4 1 7 4 7 8 18 9 46 10 10 5 8 20 47 48 23 11 5 49 24 25 12 50 11 51 ...
result:
ok ok
Test #41:
score: 22
Accepted
time: 94ms
memory: 12420kb
input:
5 227 1768 690 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 51...
output:
345 323 164 141 168 79 14 103 88 116 108 207 247 241 29 122 314 130 3 123 122 272 273 128 86 55 269 182 140 266 104 38 109 305 18 143 52 230 133 156 136 298 21 275 148 172 154 225 26 113 44 216 236 21 87 245 223 130 51 84 278 57 88 181 293 199 289 134 106 74 108 15 272 42 63 229 105 3 171 194 7 10 2...
result:
ok ok
Test #42:
score: 22
Accepted
time: 87ms
memory: 10508kb
input:
5 139 2287 2214 1 2 1 3 2 4 2 5 3 6 3 7 4 8 4 9 5 10 5 11 6 12 6 13 7 14 7 15 8 16 8 17 9 18 9 19 10 20 10 21 11 22 11 23 12 24 12 25 13 26 13 27 14 28 14 29 15 30 15 31 16 32 16 33 17 34 17 35 18 36 18 37 19 38 19 39 20 40 20 41 21 42 21 43 22 44 22 45 23 46 23 47 24 48 24 49 25 50 25 51 26 52 26 5...
output:
695 1 56 2 3 3 3 4 258 1 5 4 6 1 478 5 1 3 6 7 7 2 8 9 10 7 5 525 11 2 2 12 553 8 536 2 553 1 526 554 5 9 4 527 10 555 13 11 14 554 12 8 15 16 528 556 529 530 557 558 13 17 18 1 555 531 1 14 19 1 20 2 532 533 1 6 21 2 22 556 15 3 7 1 23 9 3 24 559 13 17 25 1 16 525 17 526 1 1 26 20 8 18 27 534 5 28 ...
result:
ok ok
Test #43:
score: 22
Accepted
time: 187ms
memory: 26712kb
input:
5 85 99108 97396 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 ...
output:
48829 6615 1493 2509 16293 2446 1378 12727 2501 10823 25502 15971 7316 14309 4646 1488 13713 13836 44033 3447 9495 26767 22714 4967 20743 5833 24457 8894 5243 6548 33985 19473 7025 8281 13532 17397 81 7340 18021 15081 11750 14781 20181 3306 17569 14162 47413 10711 45500 566 244 14100 3716 46023 1602...
result:
ok ok
Test #44:
score: 22
Accepted
time: 143ms
memory: 24248kb
input:
5 221 97581 86531 1 2 1 3 1 4 4 5 5 6 1 7 4 8 4 9 7 10 2 11 2 12 2 13 9 14 10 15 13 16 4 17 12 18 10 19 16 20 17 21 6 22 18 23 8 24 17 25 22 26 16 27 22 28 8 29 8 30 11 31 21 32 23 33 19 34 9 35 25 36 10 37 1 38 7 39 38 40 38 41 6 42 35 43 36 44 20 45 20 46 16 47 22 48 21 49 43 50 17 51 17 52 39 53 ...
output:
126 1 4 1 2 3 4 5 6 6 7 8 9 1 10 11 12 9 13 14 15 10 2 16 17 18 4 1 19 20 21 22 23 10 24 25 26 27 28 5 29 30 31 7 32 33 34 35 1 2 36 37 3 38 11 39 40 5 41 42 43 44 45 46 6 47 48 49 50 51 8 52 53 7 6 13 54 55 56 57 58 10 59 60 61 62 63 64 65 9 8 66 67 68 69 70 71 72 73 74 75 76 12 77 18 78 79 80 81 8...
result:
ok ok
Test #45:
score: 22
Accepted
time: 140ms
memory: 23020kb
input:
5 125 98543 89905 1 2 2 3 1 4 4 5 4 6 1 7 6 8 1 9 3 10 4 11 7 12 9 13 1 14 4 15 7 16 8 17 5 18 8 19 3 20 6 21 5 22 7 23 6 24 4 25 9 26 8 27 8 28 2 29 9 30 3 31 2 32 1 33 1 34 3 35 9 36 2 37 5 38 8 39 5 40 3 41 6 42 1 43 1 44 8 45 3 46 7 47 5 48 3 49 5 50 9 51 8 52 7 53 7 54 8 55 4 56 9 57 6 58 5 59 ...
output:
10182 1 1 2 7 3 4 5 6 7 8 1 9 10 1 4 2 1 6 3 8 2 1 4 3 1 3 5 4 8 11 12 8 2 3 9 6 4 6 9 7 4 4 9 10 11 12 10 13 11 8 5 14 5 6 10 6 11 13 12 15 9 12 13 8 14 9 10 10 15 11 7 16 12 8 2 14 13 7 16 8 14 13 9 3 14 9 10 11 17 12 15 13 5 10 16 6 15 14 15 18 15 7 11 17 8 18 11 12 16 17 12 17 19 16 13 13 14 19 ...
result:
ok ok
Test #46:
score: 22
Accepted
time: 111ms
memory: 31912kb
input:
5 1256 83133 86248 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 5...
output:
31782 4472 1039 7847 16742 16644 24506 28185 11040 2802 5593 9864 27444 26883 11471 22261 14936 5158 2323 8978 28698 19727 24012 17356 12029 19708 20233 21472 18180 29700 9449 21908 11785 17934 13680 15117 12549 14901 14594 19584 3386 5105 15118 4727 11811 12039 24897 13846 2020 7902 1331 5924 20857...
result:
ok ok
Test #47:
score: 22
Accepted
time: 83ms
memory: 15360kb
input:
5 337 8058 14070 1 2 1 3 2 4 2 5 1 6 1 7 6 8 3 9 1 10 8 11 4 12 11 13 8 14 1 15 10 16 4 17 11 18 7 19 8 20 4 21 1 22 8 23 3 24 11 25 12 26 3 27 9 28 6 29 4 30 3 31 11 32 7 33 4 34 9 35 10 36 4 37 4 38 5 39 8 40 3 41 9 42 9 43 4 44 10 45 4 46 5 47 4 48 4 49 6 50 10 51 7 52 11 53 5 54 12 55 12 56 5 57...
output:
4114 1 2 3 4 5 6 7 5 8 9 10 11 12 6 13 14 15 9 16 17 18 1 19 20 21 22 23 24 25 2 1 26 2 27 28 29 30 4 31 32 33 34 1 35 1 4 36 37 8 3 38 39 3 40 41 12 13 42 43 44 45 46 2 47 48 49 50 51 52 53 54 55 56 9 57 4 58 59 60 61 62 7 14 63 64 65 19 23 24 8 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 10 82...
result:
ok ok
Test #48:
score: 22
Accepted
time: 132ms
memory: 16836kb
input:
5 443 9541 12325 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 11 11 12 12 13 13 14 14 15 15 16 16 17 17 18 18 19 19 20 20 21 21 22 22 23 23 24 24 25 25 26 26 27 27 28 28 29 29 30 30 31 31 32 32 33 33 34 34 35 35 36 36 37 37 38 38 39 39 40 40 41 41 42 42 43 43 44 44 45 45 46 46 47 47 48 48 49 49 50 50 51 ...
output:
2862 2368 1599 439 990 235 417 503 2518 1250 1260 545 141 380 1511 1834 1092 357 2294 418 1149 430 463 577 72 402 2749 2314 555 705 1383 2084 249 645 11 799 445 70 2833 1126 438 100 1585 120 1073 1038 593 379 1843 137 2150 2556 2194 194 19 2654 803 929 1855 336 1686 535 2050 2691 1966 1587 1551 2607...
result:
ok ok
Subtask #6:
score: 0
Skipped
Dependency #1:
100%
Accepted
Dependency #2:
0%