QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#767442#7195. Non-descending Sequencedongyc666AC ✓48ms19660kbC++17692b2024-11-20 20:57:442024-11-20 20:57:45

Details

Tip: Click on the bar to expand more detailed information

Test #1:

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

input:

2
1 1

output:

3

result:

ok 1 number(s): "3"

Test #2:

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

input:

3
1 2 4

output:

19

result:

ok 1 number(s): "19"

Test #3:

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

input:

1
0

output:

1

result:

ok 1 number(s): "1"

Test #4:

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

input:

10
2 0 2 0 1 1 1 2 0 1

output:

2

result:

ok 1 number(s): "2"

Test #5:

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

input:

10
1 9 5 10 9 2 3 0 3 8

output:

30

result:

ok 1 number(s): "30"

Test #6:

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

input:

10
5 13 10 9 13 1 20 6 10 5

output:

546

result:

ok 1 number(s): "546"

Test #7:

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

input:

10
20 35 10 30 3 34 24 39 12 49

output:

100

result:

ok 1 number(s): "100"

Test #8:

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

input:

10
62 65 20 53 87 84 61 68 38 46

output:

376

result:

ok 1 number(s): "376"

Test #9:

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

input:

10
51 223 427 369 264 124 222 241 87 496

output:

1041

result:

ok 1 number(s): "1041"

Test #10:

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

input:

10
979 399 460 97 912 441 201 975 168 999

output:

1963

result:

ok 1 number(s): "1963"

Test #11:

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

input:

10
1566 1646 139 307 1044 1630 1804 1297 1570 300

output:

720

result:

ok 1 number(s): "720"

Test #12:

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

input:

10
208 4884 3032 3287 328 3351 244 1250 3797 528

output:

1808

result:

ok 1 number(s): "1808"

Test #13:

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

input:

10
39532 139764 61334 65512 103253 123977 122087 108745 39728 21293

output:

1422

result:

ok 1 number(s): "1422"

Test #14:

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

input:

10
973577511 924860842 135145374 333683082 866710766 260390187 469183413 342124177 106180997 379641830

output:

966

result:

ok 1 number(s): "966"

Test #15:

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

input:

20
1 1 1 2 1 2 2 0 2 0 2 0 1 0 2 1 1 2 2 2

output:

22

result:

ok 1 number(s): "22"

Test #16:

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

input:

20
6 6 5 5 2 7 0 5 3 6 10 4 1 8 8 2 5 4 3 3

output:

290

result:

ok 1 number(s): "290"

Test #17:

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

input:

20
2 1 8 0 19 20 8 16 11 20 20 8 13 11 17 19 7 12 9 6

output:

2001

result:

ok 1 number(s): "2001"

Test #18:

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

input:

20
40 21 42 21 14 27 27 7 2 32 22 14 26 4 28 39 37 5 8 39

output:

1970

result:

ok 1 number(s): "1970"

Test #19:

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

input:

20
78 75 94 4 13 6 51 28 52 78 3 26 52 42 1 18 95 72 54 91

output:

1539

result:

ok 1 number(s): "1539"

Test #20:

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

input:

20
10 270 340 224 127 187 230 152 197 233 493 433 138 361 167 140 366 465 257 170

output:

1935

result:

ok 1 number(s): "1935"

Test #21:

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

input:

20
194 886 826 704 826 197 704 381 870 21 547 538 383 849 840 79 569 417 456 717

output:

1724

result:

ok 1 number(s): "1724"

Test #22:

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

input:

20
1792 835 280 1526 1597 1080 17 1145 662 509 321 82 44 834 1986 994 72 958 1526 158

output:

780

result:

ok 1 number(s): "780"

Test #23:

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

input:

20
3995 2878 3414 2085 743 3302 1358 2761 3056 111 669 513 2669 3898 3981 3823 558 3778 1877 2292

output:

1451

result:

ok 1 number(s): "1451"

Test #24:

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

input:

20
98586 135 173408 123216 110862 108939 42264 93181 147637 23742 100694 143247 137041 117120 106635 17987 69523 117710 62735 90244

output:

1727

result:

ok 1 number(s): "1727"

Test #25:

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

input:

20
493162110 617798000 877433677 466634030 451772649 258200693 594895022 186381220 506683101 268620545 878383595 136682117 936239838 463837203 458594696 348575459 292838957 234184881 137896917 577469970

output:

1329

result:

ok 1 number(s): "1329"

Test #26:

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

input:

50
2 2 0 2 0 1 2 2 1 2 0 1 1 1 0 0 0 2 0 2 1 0 0 0 1 2 0 2 1 1 2 2 2 2 0 2 2 2 1 0 1 0 0 1 0 1 1 2 1 0

output:

1

result:

ok 1 number(s): "1"

Test #27:

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

input:

50
5 9 0 3 7 1 9 1 10 0 1 9 4 1 7 8 0 5 0 6 5 4 8 2 9 9 10 8 5 7 1 8 5 2 8 1 2 7 8 1 2 10 1 9 4 3 6 7 9 10

output:

1709

result:

ok 1 number(s): "1709"

Test #28:

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

input:

50
10 9 0 10 19 4 5 2 2 15 19 6 18 2 16 10 18 18 14 2 20 8 20 8 2 15 4 15 10 18 19 4 6 7 6 20 9 7 19 10 19 15 2 19 3 8 15 1 3 8

output:

975

result:

ok 1 number(s): "975"

Test #29:

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

input:

50
22 28 11 20 21 7 34 14 49 30 4 10 34 13 28 10 13 48 13 44 34 18 7 12 38 25 10 9 13 17 35 18 33 18 44 43 33 4 4 21 49 22 24 31 45 27 28 21 15 50

output:

523

result:

ok 1 number(s): "523"

Test #30:

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

input:

50
35 75 70 5 15 6 59 76 17 62 90 93 16 65 87 39 83 91 61 51 12 40 26 78 82 24 82 40 42 23 68 46 70 43 74 60 69 96 56 22 78 84 87 33 96 7 80 2 97 42

output:

1935

result:

ok 1 number(s): "1935"

Test #31:

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

input:

50
85 149 374 23 279 129 10 118 293 369 371 194 352 142 251 461 415 436 421 141 81 70 135 208 95 294 115 257 471 376 291 318 284 266 176 458 124 423 218 126 219 417 277 24 296 140 201 485 453 493

output:

124

result:

ok 1 number(s): "124"

Test #32:

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

input:

50
524 742 469 379 797 481 92 515 265 401 667 543 133 418 334 841 9 830 986 409 198 430 821 791 665 765 517 190 654 92 73 428 737 185 741 148 160 313 296 864 418 75 538 104 240 715 189 927 941 533

output:

1737

result:

ok 1 number(s): "1737"

Test #33:

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

input:

50
1589 102 1960 1323 1626 1131 1315 226 78 620 412 1663 1721 1618 1639 939 1071 1129 1535 395 395 444 9 1733 222 1062 340 1988 1506 397 1339 995 1107 1103 1654 530 729 1208 683 757 498 1752 1320 1426 1795 1030 1095 1873 304 964

output:

969

result:

ok 1 number(s): "969"

Test #34:

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

input:

50
2012 2021 1846 2087 304 2232 1016 4110 2493 3994 4691 2070 2882 2480 4322 707 2610 2350 1060 3425 729 4710 208 2479 340 2853 4459 1737 3819 4748 1632 3442 21 1475 940 4368 2348 1899 3098 1793 4831 149 741 4585 1118 800 752 1796 1954 2384

output:

606

result:

ok 1 number(s): "606"

Test #35:

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

input:

50
133469 164537 1268 81139 83052 118006 158748 107252 134145 34634 193541 80632 36029 131949 55825 121570 120138 123751 20337 86486 32299 49755 77188 122277 179571 12705 26283 60414 127234 34997 157452 126750 142156 143726 135686 198840 12434 33654 134996 83902 23335 59035 54900 33591 137834 66669 ...

output:

933

result:

ok 1 number(s): "933"

Test #36:

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

input:

50
535610254 655140276 662073435 570519581 944150739 366956124 488109715 382715859 76785629 230749771 933073109 948208947 756626157 57807639 248897303 499254145 447253600 662477004 321861550 549640308 913086934 199030325 528031708 797417922 164018257 755208817 734026448 257064816 837333435 938866469...

output:

308

result:

ok 1 number(s): "308"

Test #37:

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

input:

100
1 2 0 0 0 2 2 2 1 0 2 2 0 0 2 1 0 0 1 1 1 1 2 2 2 2 1 1 0 0 0 2 1 1 1 1 2 0 2 2 1 2 1 1 0 2 0 2 0 0 2 2 0 0 0 0 1 1 2 1 0 1 1 1 1 2 2 2 1 2 0 0 1 0 2 1 2 2 1 1 0 0 2 2 1 0 2 2 2 2 2 2 1 1 0 2 0 2 2 0

output:

1

result:

ok 1 number(s): "1"

Test #38:

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

input:

100
0 10 10 0 0 9 2 10 3 4 2 9 6 6 7 10 3 3 9 1 2 5 10 6 7 6 7 9 10 0 0 1 8 3 5 10 6 9 10 4 7 1 4 1 5 2 4 1 1 9 8 6 1 8 8 4 8 1 3 6 6 8 2 0 6 0 4 4 5 3 3 1 6 8 5 0 3 7 0 5 9 1 2 2 6 7 8 5 3 7 4 1 2 4 5 8 6 6 10 8

output:

1130

result:

ok 1 number(s): "1130"

Test #39:

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

input:

100
3 13 17 13 17 6 20 19 9 16 19 8 12 18 11 19 9 17 4 16 1 7 12 0 4 4 5 10 6 1 5 6 9 19 2 11 7 20 4 20 1 0 2 12 15 10 9 17 10 5 4 13 12 7 0 15 15 20 4 12 8 0 7 11 6 6 14 3 18 0 17 11 5 11 5 18 5 16 13 15 1 4 9 7 7 11 3 5 1 0 17 7 12 2 18 18 19 19 14 15

output:

1002

result:

ok 1 number(s): "1002"

Test #40:

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

input:

100
42 9 50 43 3 27 16 28 35 6 0 0 21 17 44 10 29 48 20 31 30 47 23 42 7 26 2 5 26 36 50 22 41 33 21 41 37 27 41 40 40 21 13 2 21 20 50 25 32 14 11 38 28 4 23 2 3 15 26 43 16 27 32 20 48 41 29 1 31 0 19 28 12 23 21 31 32 36 23 45 41 48 13 19 8 24 25 20 9 9 28 17 17 4 12 15 16 46 17 40

output:

347

result:

ok 1 number(s): "347"

Test #41:

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

input:

100
81 88 44 29 98 91 94 87 91 31 90 27 25 18 17 42 92 27 11 18 16 0 95 5 33 79 20 75 47 95 48 100 51 94 61 100 17 30 83 49 5 50 7 51 4 40 46 45 54 60 30 97 43 61 95 9 32 57 79 48 57 39 12 12 23 59 89 61 81 79 93 11 74 98 83 14 61 46 7 46 30 12 85 51 37 19 50 45 44 26 77 6 66 56 43 23 73 11 62 92

output:

889

result:

ok 1 number(s): "889"

Test #42:

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

input:

100
300 278 390 82 169 215 356 8 187 428 494 258 18 379 45 26 90 355 443 444 161 414 436 250 348 361 139 63 419 274 168 279 416 288 219 354 55 205 407 213 135 435 405 28 281 155 379 113 87 239 308 258 372 162 135 239 292 495 102 328 105 448 285 493 233 333 122 417 254 438 242 232 442 86 5 204 281 44...

output:

375

result:

ok 1 number(s): "375"

Test #43:

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

input:

100
618 836 796 163 378 762 816 438 188 604 210 279 527 1000 280 382 82 17 6 974 897 101 631 715 180 366 593 918 855 564 167 597 172 152 637 126 100 706 288 991 685 105 11 516 932 419 187 856 693 654 287 544 30 632 680 298 27 361 309 418 684 783 601 810 135 570 333 44 113 512 243 884 845 700 21 569 ...

output:

1021

result:

ok 1 number(s): "1021"

Test #44:

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

input:

100
562 1081 582 369 688 913 1568 512 279 1833 6 1582 1365 936 616 744 1067 782 934 728 1701 677 1991 541 1434 802 594 1306 701 821 1637 1134 72 168 1118 1089 1169 1209 1955 1705 1440 814 120 970 1150 1252 1536 934 1986 424 1811 1116 276 1812 167 480 1895 1204 1056 915 1753 218 1709 1718 708 1176 17...

output:

1564

result:

ok 1 number(s): "1564"

Test #45:

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

input:

100
4023 3135 2466 2380 1947 353 2972 100 4582 4067 1101 4621 3542 3811 957 2958 2559 217 2162 1094 2766 2179 4245 3709 844 1645 4484 1178 3680 545 362 4004 4483 2113 3362 325 4741 3534 3713 2482 1705 167 422 1043 2146 2120 3944 496 13 3092 1621 3016 1445 2950 749 2580 765 4651 3637 53 2429 1172 401...

output:

1549

result:

ok 1 number(s): "1549"

Test #46:

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

input:

100
164359 187219 39678 156040 108480 124443 101863 9408 27318 53456 164752 107800 182979 198988 51675 188771 121988 24186 67994 117859 107271 131687 59799 192297 192628 76337 101282 27846 179114 193496 13209 46818 53802 71673 149910 189362 24991 51150 183036 122461 159913 99169 114885 83758 177177 ...

output:

1103

result:

ok 1 number(s): "1103"

Test #47:

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

input:

100
652221851 845340868 613536607 608266625 678559956 851582809 13994284 381530148 39098335 20699325 231683009 245050437 855892175 362492092 542694312 346542296 17357626 115282364 241066500 411142758 89147361 708706706 922886778 370626626 684913669 379051236 356922192 113686684 305791974 32789741 30...

output:

1176

result:

ok 1 number(s): "1176"

Test #48:

score: 0
Accepted
time: 4ms
memory: 7992kb

input:

500
2 2 2 2 1 2 0 1 2 1 0 0 1 2 1 0 1 2 1 0 0 2 1 1 1 1 0 2 1 2 1 0 1 1 1 0 1 1 1 2 0 1 0 1 1 0 0 0 0 2 0 2 1 2 2 1 0 0 1 1 2 0 0 0 2 0 0 0 0 2 2 1 1 0 0 2 0 1 2 0 2 1 0 0 2 0 0 0 0 0 0 1 2 0 1 0 2 0 1 0 1 1 1 2 2 2 2 2 0 0 2 0 2 0 1 0 2 0 2 1 2 1 0 2 1 1 2 0 0 2 2 1 0 2 0 0 0 2 0 0 0 1 1 1 1 2 2 1 ...

output:

7

result:

ok 1 number(s): "7"

Test #49:

score: 0
Accepted
time: 4ms
memory: 8800kb

input:

500
4 10 2 1 4 0 10 7 3 10 7 1 4 8 6 2 5 3 0 4 5 7 2 8 6 9 9 1 10 8 3 2 2 0 7 9 7 0 2 10 6 2 0 9 1 0 2 4 8 10 5 4 10 7 9 1 1 4 2 10 5 0 7 6 4 8 7 10 6 8 4 3 4 7 7 9 2 4 8 3 5 9 2 6 7 3 6 3 8 0 9 5 3 1 4 7 1 6 5 2 1 1 5 9 1 9 8 2 5 1 10 5 1 0 2 4 8 4 3 1 1 4 7 0 3 3 1 0 1 1 8 10 0 2 5 8 0 7 9 0 1 0 9...

output:

6

result:

ok 1 number(s): "6"

Test #50:

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

input:

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

output:

961

result:

ok 1 number(s): "961"

Test #51:

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

input:

500
49 25 13 14 19 8 19 9 30 22 1 43 32 12 39 41 24 26 4 46 27 39 8 31 15 36 47 18 22 32 14 0 24 29 9 0 30 14 5 7 32 33 23 12 15 28 39 15 3 28 22 41 16 22 2 22 34 28 14 4 24 45 23 43 24 23 33 7 9 30 7 11 6 25 36 24 11 30 8 44 48 36 0 10 14 4 34 29 13 41 36 22 19 12 22 28 13 16 31 34 41 40 23 4 0 5 1...

output:

1577

result:

ok 1 number(s): "1577"

Test #52:

score: 0
Accepted
time: 4ms
memory: 9128kb

input:

500
36 49 89 80 99 9 84 95 52 13 73 69 85 15 93 11 72 60 79 1 26 86 48 79 20 69 16 11 38 12 46 54 17 6 12 88 98 91 33 15 19 63 69 30 63 21 12 44 27 70 58 60 65 39 19 9 86 95 8 71 97 27 79 56 78 42 93 24 45 73 17 4 98 90 56 78 97 1 54 10 41 16 73 63 91 97 96 69 85 77 54 60 89 35 80 56 87 76 49 44 60 ...

output:

1421

result:

ok 1 number(s): "1421"

Test #53:

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

input:

500
213 199 71 223 290 268 144 12 243 446 158 15 404 344 226 319 451 143 479 389 278 248 78 249 247 368 124 296 415 34 227 356 473 440 310 145 449 313 295 453 424 131 319 142 425 227 11 459 320 374 219 142 223 440 213 343 440 374 179 425 130 245 343 12 478 179 433 194 470 224 443 280 434 215 296 433...

output:

422

result:

ok 1 number(s): "422"

Test #54:

score: 0
Accepted
time: 4ms
memory: 8212kb

input:

500
331 3 140 873 598 295 912 684 488 120 555 763 920 176 222 154 492 877 13 505 185 490 446 845 324 951 240 745 301 105 641 227 685 370 67 557 34 779 239 431 759 737 373 9 875 278 915 196 997 668 654 926 213 19 688 950 92 480 498 633 708 566 468 394 657 651 496 471 479 109 597 519 781 617 344 714 1...

output:

804

result:

ok 1 number(s): "804"

Test #55:

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

input:

500
1225 397 1711 288 398 382 1998 894 708 1982 1522 41 1072 1547 1376 741 1874 1117 1900 86 1388 1228 1722 20 767 1349 1872 624 1480 1863 1096 1383 72 545 544 469 1138 96 1868 464 920 1310 1228 974 1563 1249 769 481 1590 123 1792 1012 1269 896 597 892 1720 69 1744 173 962 1341 1702 1080 1444 1820 5...

output:

969

result:

ok 1 number(s): "969"

Test #56:

score: 0
Accepted
time: 4ms
memory: 9160kb

input:

500
3256 805 2769 2407 4799 2246 1115 4148 1853 4665 2753 2241 2294 1008 1349 4648 2471 3490 3055 2978 3561 423 1093 1268 1553 3536 387 267 3031 1279 3082 3108 1436 2258 4892 824 3907 829 699 2292 2631 1786 891 2641 4413 4469 2261 4450 2983 1084 335 1420 910 1513 2187 2362 4102 1890 3062 2156 2992 4...

output:

1999

result:

ok 1 number(s): "1999"

Test #57:

score: 0
Accepted
time: 4ms
memory: 9080kb

input:

500
152440 119075 99905 81887 124532 192123 40810 142964 137432 127005 98319 40102 99741 17178 27176 108645 116551 76302 123743 159534 101932 188609 150371 187091 59198 36860 103947 69641 89436 109397 3798 32220 139740 198892 46426 139918 48667 189225 137700 163611 188028 87051 184249 5436 182776 17...

output:

262

result:

ok 1 number(s): "262"

Test #58:

score: 0
Accepted
time: 4ms
memory: 8608kb

input:

500
158268721 318290493 748319408 961198991 88988219 245192325 465124473 838540736 808350310 423862478 447735705 520272707 673730595 733011961 395354979 221310499 3691577 444028069 391676356 86512268 138051417 612658198 215508063 970824188 163936730 635304362 412722169 920807162 196038588 91665071 1...

output:

13

result:

ok 1 number(s): "13"

Test #59:

score: 0
Accepted
time: 8ms
memory: 12092kb

input:

1000
2 1 2 1 2 1 1 1 1 2 2 1 2 0 2 0 1 1 0 2 2 1 1 2 2 1 2 2 2 0 0 2 1 1 2 0 2 2 0 2 1 0 1 2 2 0 0 1 0 1 1 1 1 0 2 2 0 2 2 1 0 2 1 2 2 2 2 2 1 2 1 0 2 2 2 0 2 0 2 2 0 2 1 1 0 1 1 1 2 2 2 2 0 0 1 1 2 1 1 2 2 1 0 1 2 1 0 1 1 1 1 0 1 1 1 2 1 1 0 0 0 0 1 1 1 0 0 1 0 0 0 0 1 2 1 0 0 2 0 2 1 0 0 2 0 2 1 0...

output:

1

result:

ok 1 number(s): "1"

Test #60:

score: 0
Accepted
time: 12ms
memory: 12744kb

input:

1000
5 5 2 8 6 3 10 10 0 10 8 1 7 9 5 3 4 6 9 8 1 1 1 2 6 9 2 8 0 1 6 6 1 0 8 1 3 3 0 1 9 4 4 4 7 2 4 6 10 10 8 4 6 4 6 6 10 3 3 1 2 9 1 10 6 4 0 5 8 0 9 4 9 8 7 0 1 0 8 2 10 7 5 10 0 5 2 6 0 10 3 9 6 8 9 10 7 6 1 2 8 8 9 5 0 10 8 10 6 6 5 3 5 6 10 9 4 2 1 4 3 4 9 1 4 3 3 7 10 3 3 0 1 3 3 7 2 9 7 5 ...

output:

11

result:

ok 1 number(s): "11"

Test #61:

score: 0
Accepted
time: 13ms
memory: 13320kb

input:

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

output:

39

result:

ok 1 number(s): "39"

Test #62:

score: 0
Accepted
time: 8ms
memory: 12680kb

input:

1000
14 43 3 36 29 7 44 38 18 44 9 47 26 24 32 24 28 29 44 7 28 26 11 7 35 18 16 48 15 30 43 21 3 45 23 40 6 45 37 26 23 46 47 43 2 16 42 31 6 47 29 34 25 24 41 29 49 40 4 48 4 39 12 37 12 44 28 21 49 36 34 19 24 35 30 20 36 11 24 24 32 4 32 33 6 47 45 28 11 5 13 40 0 43 35 20 4 46 2 9 14 40 43 16 5...

output:

416

result:

ok 1 number(s): "416"

Test #63:

score: 0
Accepted
time: 12ms
memory: 12824kb

input:

1000
2 84 7 37 55 27 58 44 53 42 24 58 63 58 89 4 23 29 37 63 30 95 59 54 10 58 70 73 43 23 83 20 71 54 92 50 14 41 51 47 29 63 70 51 84 44 42 89 14 22 45 89 1 93 5 15 83 93 49 20 53 86 100 28 99 51 56 77 44 51 73 32 61 60 9 69 19 31 32 87 95 17 84 48 36 99 23 73 38 21 24 34 64 63 22 28 60 72 34 44 ...

output:

472

result:

ok 1 number(s): "472"

Test #64:

score: 0
Accepted
time: 12ms
memory: 11884kb

input:

1000
380 206 229 22 242 274 280 492 399 36 314 413 163 11 265 220 342 54 453 67 416 204 270 307 462 157 469 355 125 95 339 193 191 328 429 281 405 109 226 401 235 114 113 14 235 456 55 260 52 154 147 320 173 50 68 415 25 102 6 155 487 90 165 190 406 376 216 339 68 111 467 425 62 141 100 303 280 204 ...

output:

1223

result:

ok 1 number(s): "1223"

Test #65:

score: 0
Accepted
time: 8ms
memory: 11764kb

input:

1000
887 905 1 765 663 832 376 307 863 456 262 702 660 107 407 785 758 123 871 500 651 687 52 139 931 933 95 933 198 594 282 83 301 424 81 652 401 782 166 773 970 942 919 620 736 846 226 82 281 873 194 483 586 489 121 266 479 900 946 505 191 694 912 470 577 521 179 755 419 456 631 711 199 970 914 84...

output:

707

result:

ok 1 number(s): "707"

Test #66:

score: 0
Accepted
time: 13ms
memory: 12424kb

input:

1000
1321 359 1627 1386 1818 307 342 1804 337 250 1748 1867 1366 831 1326 1075 362 1720 1251 1470 331 1162 1662 1766 1655 859 651 1873 1940 530 1118 1748 387 579 321 1620 1659 1836 786 1867 1231 275 1059 454 1708 1571 499 291 1291 1601 688 938 1100 833 1835 1141 408 668 977 536 1315 1788 1777 1216 1...

output:

1745

result:

ok 1 number(s): "1745"

Test #67:

score: 0
Accepted
time: 13ms
memory: 13568kb

input:

1000
1731 3050 4073 2405 1614 4534 1671 4143 3652 1196 1187 3035 106 3545 3659 3569 2740 2688 233 4621 4237 1558 1273 2628 2211 3605 3855 2497 4789 348 3031 2334 2195 3196 675 2063 1079 845 3051 2232 113 317 957 1171 2043 2836 184 1845 2906 3590 677 4946 2877 1090 2482 4741 4923 4976 361 1897 3386 8...

output:

796

result:

ok 1 number(s): "796"

Test #68:

score: 0
Accepted
time: 8ms
memory: 11620kb

input:

1000
94676 143159 25763 171311 116979 109378 170459 58092 156167 142801 77414 104421 80690 12927 7993 103818 123107 17874 166587 189126 141388 145914 144147 5417 34814 129458 13637 116653 176116 89251 21879 58722 107981 38360 148105 73643 27182 174628 195743 14777 155642 48091 130189 2935 47171 3656...

output:

535

result:

ok 1 number(s): "535"

Test #69:

score: 0
Accepted
time: 13ms
memory: 13192kb

input:

1000
470572295 27691320 771944928 960610185 438355861 288705168 844996308 14900006 463492737 978172664 495428591 707906958 844032730 228110528 118650790 103493735 756603040 450873374 666497098 458659650 358115866 879008587 223164392 867327952 319051187 222465150 990360028 249216185 431545709 4403086...

output:

1906

result:

ok 1 number(s): "1906"

Test #70:

score: 0
Accepted
time: 38ms
memory: 19328kb

input:

2000
0 2 2 0 0 2 2 2 0 2 0 0 2 0 2 1 0 2 1 2 0 0 1 0 0 2 1 1 1 1 0 2 0 2 0 0 0 0 0 2 1 1 0 2 2 0 0 1 1 0 2 1 2 2 2 0 1 1 2 0 1 2 0 0 0 2 1 2 2 1 1 1 0 1 1 0 0 2 2 0 1 2 1 1 1 0 0 0 1 2 1 0 2 1 2 1 2 0 2 1 0 0 1 2 2 2 1 2 2 1 0 2 1 0 1 0 1 2 1 1 2 1 2 2 1 2 2 1 2 0 0 0 1 0 2 0 2 1 2 0 2 1 2 0 0 0 1 2...

output:

1

result:

ok 1 number(s): "1"

Test #71:

score: 0
Accepted
time: 45ms
memory: 19392kb

input:

2000
2 8 9 3 0 1 4 10 2 1 0 3 1 4 7 8 9 1 1 7 1 7 4 8 10 2 6 8 10 4 8 5 6 6 6 9 7 2 5 3 3 10 7 2 9 9 6 3 4 3 3 4 4 10 0 5 5 3 8 7 1 6 8 10 8 1 1 3 0 8 6 10 7 8 2 10 8 0 3 0 0 0 6 3 3 5 10 9 8 7 5 10 7 7 0 10 4 5 4 9 10 1 10 4 4 4 9 8 1 3 4 6 9 8 6 0 8 0 5 9 6 10 1 8 10 3 3 10 0 3 6 5 0 10 5 4 8 1 1 ...

output:

1

result:

ok 1 number(s): "1"

Test #72:

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

input:

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

output:

855

result:

ok 1 number(s): "855"

Test #73:

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

input:

2000
0 25 45 21 22 34 12 29 27 22 7 40 46 23 31 25 43 40 21 20 5 43 30 32 17 35 11 19 21 22 19 32 38 48 47 17 27 16 19 27 16 45 8 44 25 32 32 46 19 3 32 49 48 38 42 23 31 9 1 27 16 18 47 4 8 29 17 0 0 36 40 11 11 8 44 16 32 2 28 14 23 38 24 27 26 27 32 39 48 47 36 37 22 7 6 10 4 46 12 15 25 34 41 34...

output:

1479

result:

ok 1 number(s): "1479"

Test #74:

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

input:

2000
14 90 59 75 44 52 18 92 85 48 15 43 33 83 13 0 60 16 5 74 37 90 43 12 61 35 73 64 99 72 24 76 15 77 81 20 72 86 5 98 3 95 21 49 96 20 95 24 84 79 88 82 97 80 78 48 100 50 52 34 0 80 30 30 30 48 1 42 22 72 66 77 9 27 72 99 69 38 52 5 42 97 24 71 26 97 91 84 9 31 4 96 31 52 66 78 77 4 96 21 18 65...

output:

1470

result:

ok 1 number(s): "1470"

Test #75:

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

input:

2000
180 394 311 421 305 36 431 348 115 80 383 72 349 128 462 488 238 427 462 293 67 269 495 168 87 137 463 405 41 157 400 440 41 243 293 52 139 175 328 339 382 322 226 156 264 16 497 414 442 334 87 157 140 402 314 454 21 144 421 446 260 16 174 121 429 268 212 29 289 306 446 487 117 347 40 499 245 3...

output:

1557

result:

ok 1 number(s): "1557"

Test #76:

score: 0
Accepted
time: 48ms
memory: 19612kb

input:

2000
373 890 537 297 426 962 776 1000 886 396 644 955 619 815 449 490 379 454 712 610 525 713 463 918 12 263 515 558 951 725 325 858 791 202 495 58 473 288 430 668 206 270 828 542 650 155 942 18 495 516 75 624 557 211 646 900 808 12 759 776 782 129 553 548 939 10 812 6 758 324 824 599 248 642 193 47...

output:

1412

result:

ok 1 number(s): "1412"

Test #77:

score: 0
Accepted
time: 48ms
memory: 19332kb

input:

2000
208 58 1289 1497 1269 521 190 10 1802 1265 296 255 1032 220 1874 688 1930 1600 1849 1978 1879 1073 647 376 1939 1778 34 1615 877 1816 956 423 293 1437 1257 1749 226 614 702 162 1150 1143 1610 1622 988 603 1936 779 825 1870 1510 1109 1190 1672 1791 607 1707 1214 960 1497 397 598 142 254 88 946 1...

output:

37

result:

ok 1 number(s): "37"

Test #78:

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

input:

2000
3068 4957 3634 3583 3223 646 1524 3402 4130 63 645 1000 4239 2202 2059 3910 3930 1652 2532 2369 1591 3996 107 4343 4076 3792 1399 1877 2 3343 4446 581 1884 3170 3461 1004 1296 1292 4345 3495 3620 4209 2102 2219 173 3452 3540 4723 1195 266 4173 1931 4203 2812 2507 172 2623 2040 895 4235 3660 195...

output:

831

result:

ok 1 number(s): "831"

Test #79:

score: 0
Accepted
time: 42ms
memory: 19464kb

input:

2000
173780 1053 83468 153602 101941 156645 81983 137141 31527 31977 58738 34630 113314 131519 9778 29719 198032 36484 175969 25293 53220 22378 10357 2105 143707 188655 112499 46532 49292 129408 119163 177291 180411 12026 7107 101514 22458 131459 194702 26843 145661 24536 13621 30527 23892 20382 602...

output:

759

result:

ok 1 number(s): "759"

Test #80:

score: 0
Accepted
time: 45ms
memory: 19528kb

input:

2000
163509452 401383403 904895875 914268288 141199075 561900423 57849570 931481975 983875233 477219481 162255148 303982487 105007156 354780995 688060040 635782263 46850726 154318609 717101670 892077355 302226811 628698912 826769646 960902543 353272690 44193189 929594453 838842273 309769836 88192332...

output:

0

result:

ok 1 number(s): "0"

Test #81:

score: 0
Accepted
time: 44ms
memory: 19660kb

input:

2000
466101416 8820925 816870790 859024409 766105067 990328414 172158664 318516825 684855008 207547279 239100648 332183915 392302532 115184372 683255703 113902070 305295330 839454720 425142325 941174280 659562017 954181600 32097179 201638341 575243364 797775884 28858218 448463826 185044955 345886382...

output:

558

result:

ok 1 number(s): "558"

Test #82:

score: 0
Accepted
time: 48ms
memory: 19432kb

input:

2000
326242442 321291157 876329350 803780530 727447546 566240049 360096687 558068029 17238564 864020360 799866283 917934406 605968981 23071396 162371500 34472816 563739933 229623537 796746492 990271206 827944381 90711444 237424714 810970360 18326611 35278713 833154692 394521867 839207501 957333084 5...

output:

0

result:

ok 1 number(s): "0"

Test #83:

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

input:

2000
333867114 928728681 493336972 601053005 352353537 142151684 474405782 313699099 349622120 594348159 876711783 946135834 893264357 930958420 10083517 660076271 338264402 767276002 20867012 186851777 332763232 711161425 442752248 904222513 92813639 788861408 932418457 340579908 9449911 421296139 ...

output:

0

result:

ok 1 number(s): "0"

Test #84:

score: 0
Accepted
time: 42ms
memory: 19544kb

input:

2000
5055297 536166203 405311886 840776417 682292237 865546966 662343804 553250303 387038385 693272177 437477417 826853616 475527024 207441662 562828242 917083505 596709006 821008331 392471180 235948702 690098439 405240332 648079782 439925604 388413242 542444103 736714930 97685107 368645165 73777554...

output:

0

result:

ok 1 number(s): "0"

Test #85:

score: 0
Accepted
time: 39ms
memory: 19484kb

input:

2000
865196324 848636435 464770446 638048892 159714582 72862381 776652899 308881373 719421941 423599975 514322917 855055044 541709827 115328685 41944039 542686959 707669963 506144441 100511835 285045628 563513510 173173957 779778388 49257622 462900270 484979640 835978695 43743148 538887577 496705896...

output:

0

result:

ok 1 number(s): "0"

Test #86:

score: 0
Accepted
time: 48ms
memory: 19472kb

input:

2000
872820996 308590312 81778068 214208793 489653282 648774017 964590921 548432577 567885363 522523993 370055844 883256472 829005203 875732064 889656057 168290413 966114567 43796904 472116002 481626199 215816008 162220156 985105922 289993421 905983518 238562335 640275169 989801191 193050122 1817815...

output:

1262

result:

ok 1 number(s): "1262"

Test #87:

score: 0
Accepted
time: 48ms
memory: 19392kb

input:

2000
27929313 916027836 993752983 158964914 745963054 77202006 931416370 451547293 900268920 810400854 446901344 763974254 411267871 152215306 737368074 720264939 372042816 728933015 843720169 530723125 720634860 298750001 190433455 530729220 127954191 992145030 887022580 230826523 68325241 79322822...

output:

802

result:

ok 1 number(s): "802"

Test #88:

score: 0
Accepted
time: 35ms
memory: 19384kb

input:

2000
35553985 228498066 53211542 956237390 75901752 653113643 119354392 543614851 232652475 909324873 7666978 497208390 329967027 60102329 921516580 345868393 999083639 414069124 846728116 579820051 594049932 624232689 395760989 140061238 276070147 598244079 691319053 692964430 722487787 257191281 3...

output:

0

result:

ok 1 number(s): "0"

Test #89:

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

input:

2000
735957279 956863871 968569258 596983926 312191101 443022426 281226436 894056061 885306454 906415157 892130017 209843054 851234482 568548447 714609249 977678969 566577745 126543633 889351471 499659852 764914529 142899182 863905822 766930676 679413124 978662074 152099985 886299151 698527877 57361...

output:

0

result:

ok 1 number(s): "0"

Extra Test:

score: 0
Extra Test Passed