QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#401951#8601. Герої та МонстриdXqwq#12 16ms3996kbC++23702b2024-04-29 17:24:322024-04-29 17:24:33

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 3
Accepted

Test #1:

score: 3
Accepted
time: 6ms
memory: 3876kb

input:

5000
1903 4400 1211 1700 2191 4378 4216 4601 2907 2029 3009 1858 4926 2981 2848 1345 689 4704 3137 51 1755 787 4679 1555 496 4259 3989 1122 3983 3966 3493 2869 4203 823 410 3144 738 41 3977 1767 2663 4779 3252 1930 4989 3003 1269 1604 3888 1737 3776 351 1035 4600 3740 1534 4846 2440 3725 838 76 2786...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #2:

score: 0
Accepted
time: 6ms
memory: 3880kb

input:

5000
47 830 2838 2650 4996 1824 865 2629 29 1135 2703 3815 4646 1142 565 1101 3002 1996 1319 426 2333 4683 1274 420 3343 1648 2806 4480 4895 1438 4760 3064 3523 4767 1879 3250 4142 604 4064 2723 3145 2663 1463 2982 4195 4422 2005 3662 1692 276 1209 4271 1709 1878 1522 2130 2216 2875 4099 2682 4706 1...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #3:

score: 0
Accepted
time: 6ms
memory: 3872kb

input:

5000
4013 1760 2726 4336 4597 3326 2242 297 977 4208 4047 1444 3596 675 145 4151 4797 2635 1464 1639 2472 4078 1814 465 11 300 3636 2529 4735 32 4937 3342 314 3957 143 1465 1604 3367 162 1919 4882 3462 3322 1966 4086 1397 3651 4367 2407 787 4395 3731 2724 2040 842 4248 1728 4463 1023 3922 3099 3887 ...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #4:

score: 0
Accepted
time: 9ms
memory: 3792kb

input:

5000
4256 1360 45 1462 4736 2351 1807 2308 3520 1265 357 2847 446 2317 1638 2817 3472 4036 1722 2165 3364 2852 2187 843 516 456 1553 3609 3264 4263 3846 908 1659 4752 920 635 3202 2080 2291 2185 4172 477 4869 462 4376 4255 4666 3686 4094 4619 4531 1406 3519 2850 359 2893 63 2432 522 2117 1168 2282 8...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #5:

score: 0
Accepted
time: 9ms
memory: 3796kb

input:

5000
4108 1176 3492 1954 2420 2760 3353 3589 3890 666 2108 4731 1318 3414 2786 829 1930 3567 335 594 2483 3142 635 2328 1604 3542 2513 541 4406 2942 2542 1133 2304 641 3856 334 2083 2329 1934 4716 2041 3674 188 1811 3439 3898 4382 1002 362 3724 554 3226 1836 137 368 410 632 1129 4508 2765 854 379 37...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #6:

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

input:

5000
1353 3491 635 4602 1156 699 1405 4303 4954 1251 1407 1982 2732 4462 761 3370 3383 3963 2174 1933 4839 3884 1633 453 4268 1790 3408 487 4593 4663 1884 2609 2501 4679 4756 3543 2644 68 3556 1390 2240 4121 3363 1144 392 2657 853 3481 4274 3187 3878 4350 122 494 4966 1033 1070 3095 2372 4278 423 24...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #7:

score: 0
Accepted
time: 9ms
memory: 3872kb

input:

5000
2178 2292 4600 363 3742 2058 2043 637 4433 4144 2768 2191 4705 3614 851 3534 3206 4898 1937 852 1891 2908 1221 3693 1389 2648 4678 2356 2850 4984 3793 2876 2803 3572 4489 595 1236 604 1344 193 2800 3423 3654 689 4734 880 734 1045 2615 4812 582 2389 3661 4349 2294 4886 2589 2459 1644 865 2365 41...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #8:

score: 0
Accepted
time: 6ms
memory: 3792kb

input:

5000
1081 3555 399 4405 890 144 3498 1382 4744 4341 4417 3580 4546 2961 2818 1751 68 2123 2051 39 984 3756 977 1225 4713 4740 765 309 1199 2559 4298 1838 1671 2207 1625 1764 4636 2920 1083 1182 3535 4715 2437 1997 3322 2889 1411 1685 1276 1357 4931 801 2203 3933 4786 2688 3747 4194 1688 1074 1156 11...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #9:

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

input:

5000
3491 1219 3234 587 2840 4720 1321 4512 2699 3931 4694 3202 427 2785 1529 3736 4225 730 4842 3467 1346 1477 2884 3270 3140 373 1685 3661 4047 103 725 4043 2578 3672 1452 4941 1955 3068 3871 3122 3533 303 4008 2470 1910 3832 1513 4893 1914 2746 2161 106 4221 4470 3913 4844 3476 4081 1213 1214 219...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Test #10:

score: 0
Accepted
time: 9ms
memory: 3860kb

input:

5000
1326 2770 2439 2702 3928 4438 513 1590 4449 4294 4820 381 2898 3027 3665 3731 4593 2308 3597 1153 2009 2982 4079 3656 4214 3071 3526 864 328 3047 331 283 3671 900 2626 3850 2043 2274 690 4147 999 1688 3877 3886 317 1541 1743 4302 2958 1322 1959 4470 2856 4046 604 2484 4669 24 4648 4851 4425 493...

output:

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
...

result:

ok 5001 numbers

Subtask #2:

score: 9
Accepted

Test #11:

score: 9
Accepted
time: 8ms
memory: 3816kb

input:

5000
2034 4850 3399 4589 4777 643 1832 1410 3705 2859 3002 1824 2063 2342 2885 1715 2531 2809 1389 1050 3167 374 242 368 4346 1850 3418 4129 4626 2762 1365 4440 3165 857 1042 61 713 2313 4467 2864 29 4725 4959 571 4753 378 4674 1960 1654 21 1704 4401 2068 3375 2092 2086 3004 4179 2865 2619 2873 4755...

output:

1674

result:

ok 1 number(s): "1674"

Test #12:

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

input:

5000
3164 3005 3927 2471 3834 3286 1963 1828 4806 2027 1836 2727 255 3460 849 112 1123 3671 59 4507 214 899 199 2640 4221 551 787 3631 3835 754 3039 115 1952 764 1799 3215 2038 2423 528 4331 4098 4043 4978 3482 4398 217 1501 4836 2499 1943 1769 3370 1627 3263 4820 27 765 992 3093 1065 4427 3073 3717...

output:

1650

result:

ok 1 number(s): "1650"

Test #13:

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

input:

5000
3937 123 4522 2530 2416 2628 183 2053 4490 3976 1469 4794 2772 1313 1671 129 402 1157 3141 3914 260 3997 2245 1008 84 109 2887 2433 1489 4690 2817 858 3442 718 3392 3804 4740 2690 2664 1110 2352 3011 2408 1334 4763 4547 4392 4985 1521 2532 4110 1233 4590 3787 1681 965 729 3871 2979 1547 1302 44...

output:

2520

result:

ok 1 number(s): "2520"

Test #14:

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

input:

5000
4959 1583 1829 3598 687 4953 3347 3771 2772 1821 1316 3698 3225 2922 559 2265 3856 476 4479 3315 2730 619 1226 203 1439 1657 2131 2347 1314 4202 3211 3573 4778 2494 1299 1525 1487 1892 86 1496 4289 1384 2757 1640 1367 2448 307 4762 1083 4143 3953 1592 1603 3533 3184 510 524 1777 2852 1776 453 6...

output:

2496

result:

ok 1 number(s): "2496"

Test #15:

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

input:

5000
3843 764 4390 4144 4885 3595 3144 2051 4735 4609 1049 1828 2591 3055 4680 2425 3651 3928 1384 4337 489 3742 4483 1073 3652 3419 3430 924 3912 1718 4127 3460 3579 1991 938 738 3756 3570 2897 1259 2504 4325 2175 3980 2197 3224 3640 3946 1676 1998 994 2472 261 2525 4278 175 2587 1984 4862 1981 875...

output:

2471

result:

ok 1 number(s): "2471"

Test #16:

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

input:

5000
3174 4007 4271 2224 2582 4317 3900 3368 1949 624 3673 2468 1541 4092 4622 4681 1540 4340 308 3651 763 1218 4075 3243 4736 109 2832 2526 4734 1588 41 101 349 301 1598 3179 3830 3040 3768 4264 2439 1466 2775 3461 3313 1425 2344 3846 2036 4755 1791 810 4916 2957 3297 3130 4791 2160 4737 107 4655 3...

output:

2447

result:

ok 1 number(s): "2447"

Test #17:

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

input:

5000
1510 1208 3421 4648 2976 4143 4896 596 330 2089 1014 2756 3209 749 1999 135 581 1337 3145 1376 1388 3523 3651 4255 4209 4691 576 3256 1972 4556 808 918 1366 3028 996 2368 181 1638 1537 687 547 4629 3766 1440 4044 1286 3988 2086 3446 4609 4299 977 4834 3260 2384 1948 4100 567 647 1338 867 3169 4...

output:

3949

result:

ok 1 number(s): "3949"

Test #18:

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

input:

5000
2373 2968 1535 3837 3598 1425 4465 2526 9 2045 3208 1366 3978 2660 2990 4579 4872 3151 1420 2932 474 4488 2162 3385 498 651 4147 779 4497 4207 3931 1637 4004 4675 3983 4036 2481 3455 1705 707 1156 4268 4509 517 3496 3214 671 3116 4503 1940 3770 3107 350 254 2605 1453 419 3179 117 1661 242 2142 ...

output:

4819

result:

ok 1 number(s): "4819"

Test #19:

score: 0
Accepted
time: 5ms
memory: 3924kb

input:

5000
1464 30 2482 2081 3223 3499 4411 1734 1714 4315 3783 329 3770 554 3708 935 2415 1592 3731 291 2413 2673 236 2625 3001 3370 4002 4011 2656 455 4869 4249 4912 1954 595 560 367 3672 1989 3560 991 2471 830 525 3177 2240 3581 2507 33 2716 4319 1488 4625 2516 1773 2512 2031 4572 1856 1447 3324 3484 3...

output:

4795

result:

ok 1 number(s): "4795"

Test #20:

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

input:

5000
4771 1693 2402 744 2676 2499 905 178 3584 2951 1591 295 1139 4603 1237 608 803 2496 3032 565 886 758 1798 1543 4191 605 2303 4196 1009 222 4925 4187 4906 1486 304 62 359 2646 959 2107 527 741 1569 2046 3438 441 2606 1311 4010 930 3850 4174 2898 1387 982 4901 4149 2352 942 4479 1721 4789 536 286...

output:

4028

result:

ok 1 number(s): "4028"

Test #21:

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

input:

5000
3998 139 4491 3750 4102 2149 1521 2002 4315 680 4659 1898 3121 162 4241 1914 3714 674 2159 2862 1685 2324 690 4312 1259 4769 774 3435 2384 2318 969 4310 3832 2287 1977 2887 3810 2440 1826 3919 3281 4125 4415 3886 2333 2782 1029 382 2449 399 1701 4359 1023 1674 4525 3808 4266 2982 331 4631 641 4...

output:

1

result:

ok 1 number(s): "1"

Test #22:

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

input:

5000
1520 4178 2161 1439 2930 3173 3400 715 4453 4073 3268 4169 93 2396 2996 2249 3812 1336 4693 866 4598 3393 2344 3944 1964 1985 740 3557 3672 4681 4290 3761 889 2469 1896 1134 4420 2112 2178 4031 3095 1359 2767 1868 1472 4463 1313 3205 4550 167 2137 3894 391 3333 590 4258 1275 3599 4852 4482 796 ...

output:

3979

result:

ok 1 number(s): "3979"

Test #23:

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

input:

5000
2636 2177 103 712 2572 4357 4535 2319 4994 623 4099 2754 4320 1431 4927 947 513 2922 4502 11 4139 4869 4979 1774 2159 916 3092 4764 735 4564 3933 1098 1558 387 1955 4905 2683 2737 1072 4235 2341 1951 3042 3593 3785 2981 3755 2425 4942 4717 4351 4305 501 3300 3604 813 861 1926 2983 2487 1494 447...

output:

3955

result:

ok 1 number(s): "3955"

Test #24:

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

input:

5000
779 1051 2701 2243 1168 2626 4914 1534 3646 4964 2663 2696 2578 3653 3305 3267 562 1158 654 4451 4020 3789 54 389 4346 1429 3793 1838 4701 1697 1142 4704 4854 2520 3453 2584 4056 371 4553 2650 2309 4370 4416 4139 3548 968 2528 4741 2224 2556 1867 1717 4962 4748 1084 2218 4371 3560 4015 35 3395 ...

output:

4825

result:

ok 1 number(s): "4825"

Test #25:

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

input:

5000
3317 265 1660 2194 3302 992 3883 3266 498 1130 4019 408 1655 4441 4968 1160 1030 34 3017 54 47 2411 2396 846 3430 4896 4423 3197 1100 1598 1225 972 3875 2756 3411 4449 204 146 1920 1928 791 3400 996 2716 3794 1535 4822 2802 1344 3419 3476 1625 1373 975 1990 2440 2239 2203 40 942 3233 603 1045 2...

output:

1

result:

ok 1 number(s): "1"

Test #26:

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

input:

5000
54 1863 637 921 3216 8 1410 4866 3497 1993 2272 4052 4512 2538 4042 4586 2521 2985 3776 2681 2406 2399 2472 3409 2012 446 3615 1639 4876 1448 4853 468 2149 1396 1288 1696 1767 589 4982 1870 3309 1933 4554 134 3927 2546 1563 1910 3745 1180 46 1101 3719 2949 458 3168 3184 763 4099 453 4435 4593 4...

output:

4776

result:

ok 1 number(s): "4776"

Test #27:

score: 0
Accepted
time: 5ms
memory: 3868kb

input:

5000
2010 975 3913 2684 1452 1884 3380 3151 2893 1159 1823 4910 2957 4878 2256 2484 578 376 2732 1008 3325 3565 1030 216 904 4671 2084 3947 226 242 3682 915 3032 3042 4157 2306 3078 4637 3230 3769 4914 2458 4586 4415 3004 3866 2722 718 1681 2338 1927 4996 292 3475 1527 1031 3931 598 820 2036 4801 26...

output:

1

result:

ok 1 number(s): "1"

Test #28:

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

input:

5000
27 4950 1857 1688 2760 4409 3888 1910 3734 4741 2319 3299 300 446 1489 315 1432 2534 4467 2169 1679 3246 4072 4973 334 2445 3367 4326 3674 754 3161 1684 92 4389 1131 2847 913 471 1882 1753 3723 2520 2635 4456 2934 2881 1586 2948 3562 3115 3960 1425 43 4698 97 54 3146 107 4979 1064 2192 2104 600...

output:

1253

result:

ok 1 number(s): "1253"

Test #29:

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

input:

5000
4249 2930 3891 4353 901 1990 4749 1000 4175 1226 4248 1401 3925 1816 1081 2991 2408 2542 849 2183 3272 951 1305 4149 4620 2916 3794 3157 4506 1429 2475 2456 1018 4326 3039 4030 848 3672 4743 2545 3894 762 172 884 3097 2531 4789 877 4599 725 4753 284 1396 3886 2524 3681 4378 946 3251 523 3364 11...

output:

1228

result:

ok 1 number(s): "1228"

Test #30:

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

input:

5000
4475 4056 10 1114 3924 4146 16 4653 3141 1056 4529 1552 2768 4342 2548 4026 2852 1508 3964 4380 3288 2341 1082 2649 2752 3941 1713 1924 2947 2794 1664 924 2861 1700 3074 4381 2102 2155 225 240 3309 22 4726 3613 3945 3736 3636 2053 1102 4745 493 2007 4266 4360 3095 3771 613 1628 139 4915 4460 41...

output:

4570

result:

ok 1 number(s): "4570"

Test #31:

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

input:

5000
4465 4341 1146 3874 2962 1252 1747 4907 2975 2586 4905 566 381 330 4156 2005 75 3657 2030 182 561 2707 910 1007 3173 289 1221 1707 2841 28 2605 1648 85 3856 1468 1142 1058 1354 2245 1135 250 1945 2352 3579 2581 3868 1441 1003 1997 219 1972 3865 694 2992 2921 2871 4911 2787 994 4485 1768 3584 39...

output:

1071

result:

ok 1 number(s): "1071"

Test #32:

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

input:

5000
4580 4605 509 2595 4569 4152 157 1077 2145 1285 1476 454 4061 2462 230 50 885 2795 1638 3014 824 4024 4117 4174 40 3036 444 4823 4709 2298 1244 2187 72 2100 4703 3533 2312 2109 3776 4258 3523 1788 3852 3671 1960 4499 2708 4254 2508 1209 2405 521 4253 1903 3111 2278 3372 3735 4207 1506 4428 1481...

output:

1

result:

ok 1 number(s): "1"

Test #33:

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

input:

5000
3799 4735 1274 4096 2769 4623 3933 4825 2269 1544 721 297 2892 3873 2186 195 1672 4453 1606 2312 739 527 1910 2525 2612 1230 311 2237 4341 4378 4434 4537 2805 3880 4127 1092 2824 3415 4584 3572 3328 3961 1052 1538 872 3209 2306 3376 2394 2387 181 4884 3258 2358 3265 2303 860 830 3177 509 3215 3...

output:

1022

result:

ok 1 number(s): "1022"

Test #34:

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

input:

5000
350 3967 2312 4604 785 3746 2069 1750 763 1502 449 2024 3362 2027 609 2147 4145 661 3447 4375 537 4652 2134 531 2050 955 4419 3338 4942 4758 1599 1746 3102 3204 501 3192 577 3456 1837 622 2225 2676 691 116 3846 1276 875 943 3677 2845 254 4007 270 4574 737 4553 972 1112 1823 4180 1863 1719 2540 ...

output:

997

result:

ok 1 number(s): "997"

Test #35:

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

input:

5000
3109 4136 1449 3647 3117 3156 2102 2766 3359 1349 87 4915 3353 964 38 1717 2852 1319 3128 4315 461 4281 543 616 35 3984 1399 624 3889 2722 3658 4698 2738 779 3542 3985 3934 2994 969 3580 2464 4666 2117 845 4151 2222 2253 1170 2473 3597 3521 687 4892 1529 591 4341 2110 292 1111 3376 2335 1473 47...

output:

1868

result:

ok 1 number(s): "1868"

Test #36:

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

input:

5000
4005 4652 3074 1072 3491 4670 2155 2306 4787 2380 4740 4067 455 400 1283 2501 2485 1310 1277 972 4412 723 834 296 4604 381 3670 3674 4054 3414 568 231 598 1045 4639 4103 3128 667 4306 3526 1293 1882 3684 4384 2445 2519 4965 949 3254 2645 3344 328 3934 3326 3644 746 868 538 3112 2805 1949 3836 3...

output:

1844

result:

ok 1 number(s): "1844"

Test #37:

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

input:

5000
4799 2911 2082 2539 1691 1747 3537 3660 902 4084 1215 4493 2445 2746 4559 3247 2359 160 3823 1512 2199 1688 4038 1172 4876 3389 304 1015 4337 1056 4802 997 3437 2419 3924 4376 2611 4643 1667 3911 2337 678 3766 4930 1342 1352 3611 3032 250 3102 471 3629 3312 4807 2220 3370 1132 1546 1471 4290 16...

output:

3345

result:

ok 1 number(s): "3345"

Test #38:

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

input:

5000
4836 300 3848 682 4967 2506 947 4358 907 2345 3369 4890 2768 4345 3849 7 4419 2875 2365 1421 338 4239 2629 3855 595 1402 4994 1044 1730 4300 3764 2897 4456 3175 4028 1052 86 1974 3648 2939 1332 140 1625 4896 4243 4604 1945 2877 2700 4126 1980 2937 1867 1227 4793 2691 2977 3148 2458 313 1878 454...

output:

3321

result:

ok 1 number(s): "3321"

Test #39:

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

input:

5000
742 4645 2110 622 1497 4179 2015 69 2283 2940 735 344 1611 558 1534 4624 2324 1910 4605 2864 3049 1278 2546 4617 2627 4206 3941 1605 2305 3551 452 3160 3031 420 114 2300 4910 132 4 4399 291 4301 2887 1817 2884 4812 4929 4221 4325 610 4427 2860 1794 545 665 4938 4368 3659 482 302 4634 1208 332 4...

output:

3297

result:

ok 1 number(s): "3297"

Test #40:

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

input:

5000
3707 2273 3749 2767 4969 2862 4181 1439 2393 194 4682 1505 1661 3203 417 1485 1064 2908 3681 4870 1400 4205 4159 1349 3511 1657 113 1418 2370 2067 2432 3584 779 1803 3468 3652 4704 4955 3721 898 568 128 2643 695 783 3834 3541 2163 1261 2467 3849 3464 3018 439 1199 4861 699 926 3351 615 1928 129...

output:

742

result:

ok 1 number(s): "742"

Subtask #3:

score: 0
Wrong Answer

Test #41:

score: 0
Wrong Answer
time: 16ms
memory: 3828kb

input:

5000
1 3 5 7 9 11 13 15 17 19 21 23 25 27 29 31 33 35 37 39 41 43 45 47 49 51 53 55 57 59 61 63 65 67 69 71 73 75 77 79 81 83 85 87 89 91 93 95 97 99 101 103 105 107 109 111 113 115 117 119 121 123 125 127 129 131 133 135 137 139 141 143 145 147 149 151 153 155 157 159 161 163 165 167 169 171 173 17...

output:

832808281
661919442
989019569
779821106
261682315
528684554
664801825
39862452
187933362
242066761
275472629
562573401
971222158
434730498
374107485
435525154
155418392
287118343
879692562
921122745
872190773
905785852
160781098
522610300
737374942
190213953
435829104
128988228
234622037
710364622
7...

result:

wrong answer 1st numbers differ - expected: '994748608', found: '832808281'

Subtask #4:

score: 0
Wrong Answer

Test #71:

score: 0
Wrong Answer
time: 0ms
memory: 3820kb

input:

300
127 142 125 327 217 438 162 129 16 370 452 170 418 357 397 446 398 597 5 296 558 159 140 566 433 132 302 565 472 513 477 198 350 467 177 160 272 155 251 440 84 176 387 112 237 578 258 278 26 74 332 6 136 400 367 273 535 146 252 141 11 484 285 465 474 512 373 462 480 207 505 580 114 22 340 42 288...

output:

1

result:

wrong answer 1st numbers differ - expected: '268091962', found: '1'

Subtask #5:

score: 0
Wrong Answer

Test #101:

score: 0
Wrong Answer
time: 16ms
memory: 3836kb

input:

5000
214 8143 377 4551 6212 1807 4966 4535 3579 997 7830 3921 7330 6511 8039 1554 3258 9014 4821 7807 1039 7535 4022 2642 2781 8442 3246 141 9033 2806 9569 8010 565 2546 6114 7896 4315 3054 384 1100 9263 9236 8117 8983 8184 2987 5491 8267 1271 5488 3990 494 2917 6363 3528 8154 3334 4216 8742 2805 53...

output:

1

result:

wrong answer 1st numbers differ - expected: '670627274', found: '1'

Subtask #6:

score: 0
Wrong Answer

Test #131:

score: 0
Wrong Answer
time: 16ms
memory: 3812kb

input:

5000
3846 2428 4235 4639 1041 2385 198 6154 6899 8917 6284 9752 8913 2027 9242 6979 498 2562 5915 3968 9943 2767 3776 3415 3532 1826 8061 9507 6540 1850 2235 7245 5751 5780 3048 23 361 2777 262 8551 4969 1367 8671 7424 504 5822 3056 6816 9246 6810 1643 8378 9672 7472 4092 8226 5973 157 9275 4757 619...

output:

691525924

result:

wrong answer 1st numbers differ - expected: '293162006', found: '691525924'

Subtask #7:

score: 0
Skipped

Dependency #4:

0%

Subtask #8:

score: 0
Skipped

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Dependency #3:

0%