QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#117422 | #30. Political Development | xiaossr# | 4 | 26ms | 6824kb | C++17 | 2.1kb | 2023-07-01 07:07:33 | 2024-05-31 18:45:41 |
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: 4
Accepted
Test #1:
score: 4
Accepted
time: 1ms
memory: 5896kb
input:
8 2 1 2 3 7 3 5 2 7 0 1 1 1 7 1 1 1 7 4 6 4 1 2
output:
2
result:
ok single line: '2'
Test #2:
score: 0
Accepted
time: 1ms
memory: 5968kb
input:
8 2 2 3 7 1 3 2 6 4 3 5 1 0 1 2 2 3 6 2 5 2 1 0
output:
2
result:
ok single line: '2'
Test #3:
score: 0
Accepted
time: 26ms
memory: 6324kb
input:
5000 2 1 1791 1 4343 2 2031 1630 1 286 2 4788 1978 3 847 2364 4193 2 88 1614 1 3321 1 1441 1 1098 1 1547 1 318 1 4939 1 697 3 1335 3973 2092 1 3700 1 3959 1 4582 2 2907 3324 1 364 1 4868 1 1406 4 1827 3291 2215 4513 2 1303 2448 3 3699 2272 775 4 3113 1333 2670 1991 2 2450 3615 4 3825 2008 1100 2938 ...
output:
2
result:
ok single line: '2'
Test #4:
score: 0
Accepted
time: 18ms
memory: 6432kb
input:
5000 2 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460 1 1460...
output:
2
result:
ok single line: '2'
Test #5:
score: 0
Accepted
time: 22ms
memory: 6428kb
input:
5000 2 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782 1 1782...
output:
2
result:
ok single line: '2'
Test #6:
score: 0
Accepted
time: 23ms
memory: 6428kb
input:
5000 2 1 1692 1 3670 1 3770 1 2722 1 2554 1 4972 1 3203 1 1406 1 62 1 2411 1 4472 1 3565 1 1465 1 4734 1 3229 1 707 1 4925 1 597 1 3764 1 1406 1 778 1 2086 1 1696 1 2956 1 707 1 1406 1 3604 1 597 1 1275 1 3203 1 707 1 4577 1 997 1 3604 1 1747 1 860 1 3565 1 3693 1 164 1 818 1 3693 1 4790 1 86 1 3969...
output:
2
result:
ok single line: '2'
Test #7:
score: 0
Accepted
time: 24ms
memory: 6412kb
input:
5000 2 1 1495 1 4736 1 2861 72 2890 4002 3751 2434 4908 3707 1698 4275 2507 2625 1942 1452 1309 2552 4 3667 4794 289 309 3334 2996 3208 1001 2408 707 3200 4272 3343 4465 4748 1352 48 2894 4367 3534 4594 4433 4265 3168 2324 2681 4909 1986 501 2958 784 4138 409 2837 4999 3840 3654 327 3620 4399 319 33...
output:
2
result:
ok single line: '2'
Test #8:
score: 0
Accepted
time: 20ms
memory: 5912kb
input:
5000 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
1
result:
ok single line: '1'
Test #9:
score: 0
Accepted
time: 1ms
memory: 6188kb
input:
1 1 0
output:
1
result:
ok single line: '1'
Test #10:
score: 0
Accepted
time: 20ms
memory: 5852kb
input:
5000 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
2
result:
ok single line: '2'
Subtask #2:
score: 0
Wrong Answer
Dependency #1:
100%
Accepted
Test #11:
score: 12
Accepted
time: 22ms
memory: 6408kb
input:
5000 2 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154 1 1154...
output:
2
result:
ok single line: '2'
Test #12:
score: 0
Accepted
time: 18ms
memory: 6664kb
input:
5000 3 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423 1 1423...
output:
2
result:
ok single line: '2'
Test #13:
score: 0
Accepted
time: 0ms
memory: 5936kb
input:
5 3 2 3 1 2 0 4 2 4 3 2 0 2 2 1 2
output:
2
result:
ok single line: '2'
Test #14:
score: 0
Accepted
time: 22ms
memory: 6672kb
input:
5000 3 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937 1 2937...
output:
2
result:
ok single line: '2'
Test #15:
score: 0
Accepted
time: 1ms
memory: 5844kb
input:
5 3 0 2 2 3 2 3 1 2 2 1 0
output:
3
result:
ok single line: '3'
Test #16:
score: 0
Accepted
time: 23ms
memory: 6384kb
input:
5000 3 1 2124 1 3797 1 4553 1 4508 1 1597 1 1937 1 4085 1 72 1 1579 1 4933 1 4085 1 4553 1 1759 1 3797 1 1579 1 2531 1 4297 1 814 1 3729 1 4070 1 1606 1 1251 1 920 1 1365 1 3586 1 2124 1 827 1 4132 1 4645 1 3586 1 3945 1 72 1 4933 1 1759 1 1365 1 3729 1 1759 1 2531 1 2715 1 1817 1 494 1 1937 1 3489 ...
output:
2
result:
ok single line: '2'
Test #17:
score: 0
Accepted
time: 0ms
memory: 5956kb
input:
5 3 2 4 3 1 4 0 2 4 0 3 1 0 3
output:
3
result:
ok single line: '3'
Test #18:
score: 0
Accepted
time: 19ms
memory: 6372kb
input:
5000 3 1 1692 1 3670 1 3770 1 2722 1 2554 1 4972 1 3203 1 1406 1 62 1 2411 1 4472 1 3565 1 1465 1 4734 1 3229 1 707 1 4925 1 597 1 3764 1 1406 1 778 1 2086 1 1696 1 2956 1 707 1 1406 1 3604 1 597 1 1275 1 3203 1 707 1 4577 1 997 1 3604 1 1747 1 860 1 3565 1 3693 1 164 1 818 1 3693 1 4790 1 86 1 3969...
output:
2
result:
ok single line: '2'
Test #19:
score: 0
Accepted
time: 20ms
memory: 5960kb
input:
5000 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
1
result:
ok single line: '1'
Test #20:
score: 0
Accepted
time: 20ms
memory: 6084kb
input:
5000 3 1 4978 1 838 1 2090 1 2059 1 3473 1 3392 1 3776 1 4073 1 1498 1 1831 1 3645 1 323 1 3789 1 3555 1 2658 1 3953 1 167 1 1424 1 1944 1 1748 1 3592 1 1697 1 3034 1 4369 1 834 1 3873 1 3964 1 2160 1 4030 1 3652 1 1931 1 3657 1 1500 1 1193 1 3550 1 3287 1 1339 1 2943 1 4697 1 1390 1 4134 1 3322 1 4...
output:
3
result:
ok single line: '3'
Test #21:
score: 0
Accepted
time: 21ms
memory: 6148kb
input:
5000 3 1 4920 1 3824 1 1763 1 785 1 1613 1 2253 1 3343 1 34 1 905 1 2732 1 2112 1 1644 1 3772 1 4254 1 1143 1 2579 1 3267 1 3263 1 3699 1 2181 1 936 1 867 1 2614 1 865 1 2998 1 901 1 2044 1 2335 1 1665 1 2048 1 571 1 2400 1 1961 1 4537 1 7 1 4327 1 2380 1 1730 1 1232 1 4381 1 154 1 2571 1 807 1 3934...
output:
3
result:
ok single line: '3'
Test #22:
score: 0
Accepted
time: 20ms
memory: 5912kb
input:
5000 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 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 4142 0 ...
output:
2
result:
ok single line: '2'
Test #23:
score: 0
Accepted
time: 24ms
memory: 6520kb
input:
5000 3 2 11 4552 2 2485 1399 2 3747 2906 3 3702 2655 2871 1 3902 2 3893 4591 1 3574 1 123 2 3269 1354 1 1201 2 662 831 7 3302 2808 4537 0 3789 2902 2028 5 3598 2273 4345 4790 2111 2 2604 3829 2 3358 2711 5 2831 3507 2723 3472 929 3 4417 1555 4746 2 640 4809 2 1518 4570 1 4562 4 3081 1145 3030 4813 3...
output:
3
result:
ok single line: '3'
Test #24:
score: 0
Accepted
time: 16ms
memory: 5984kb
input:
5000 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
2
result:
ok single line: '2'
Test #25:
score: 0
Accepted
time: 21ms
memory: 6752kb
input:
5000 3 1 2358 4 3124 1577 4532 34 4 1520 3135 2550 834 1 4310 1 1608 3 1776 3497 4111 1 1663 3 4052 4660 2936 2 4763 1683 2 1517 3390 2 3754 2875 8 916 1110 3367 4812 249 955 3275 3221 4 2211 1121 2834 2598 2 4492 2100 5 4962 238 2864 2019 3400 2 84 327 4 4617 3874 450 2285 1 3115 2 3406 4305 2 843 ...
output:
3
result:
ok single line: '3'
Test #26:
score: 0
Accepted
time: 20ms
memory: 6472kb
input:
5000 3 2 2861 4217 3 4808 3899 27 3 3586 3740 4883 1 1744 2 4563 2822 2 1890 2075 0 2 3889 1490 3 1820 3858 3879 1 3255 1 3718 7 399 4255 258 1374 2121 2455 1706 2 2584 4882 1 1780 3 4531 3796 1657 1 772 3 410 4026 1371 2 4339 4381 1 3080 1 1751 3 3381 3040 4741 8 2031 1620 2804 3126 4553 2583 2013 ...
output:
2
result:
ok single line: '2'
Test #27:
score: 0
Accepted
time: 18ms
memory: 6376kb
input:
5000 3 2 3886 4976 2 3410 4204 2 3696 1856 2 4926 1743 2 1749 138 2 836 730 2 710 1407 2 3679 2777 2 4941 4813 2 1312 1246 2 2047 1575 2 2139 2514 2 1689 3228 2 985 4894 2 980 3231 2 4331 3377 2 747 321 2 1144 2248 2 2206 154 2 685 4436 2 1662 4256 2 4972 4453 2 1962 2239 2 2400 2443 2 2984 2149 2 1...
output:
2
result:
ok single line: '2'
Test #28:
score: 0
Accepted
time: 23ms
memory: 6436kb
input:
5000 3 1 3604 3 889 3044 3781 1 4328 3 1488 168 4629 1 21 1 89 2 1693 1670 4 2047 1219 3456 4971 2 30 3021 3 4898 4739 964 3 856 1092 2052 4 280 1259 123 908 4 78 2806 4916 4273 1 1107 3 4331 3110 283 2 1192 1909 2 588 3144 1 1046 2 943 945 3 2406 4507 2333 1 1445 3 3254 4 3462 1 1564 3 4527 4284 36...
output:
2
result:
ok single line: '2'
Test #29:
score: 0
Accepted
time: 18ms
memory: 6604kb
input:
5000 3 2 2737 1216 2 858 2485 2 2350 937 2 839 1170 2 3867 4444 2 892 3248 2 3162 712 2 4810 3067 2 2171 3160 2 3986 2610 2 665 604 2 2257 3122 2 516 3537 2 1190 4572 2 3766 4244 2 2037 377 2 3845 1591 2 3360 4427 2 4010 3519 2 1606 385 2 2584 191 2 4455 4176 2 499 4676 2 2624 1931 2 3467 3909 2 351...
output:
2
result:
ok single line: '2'
Test #30:
score: 0
Accepted
time: 23ms
memory: 6588kb
input:
5000 3 2 3352 2300 2 259 1492 2 3352 860 2 2079 225 2 1765 1736 1 696 2 696 3466 1 696 2 1491 2988 2 1726 1673 2 3099 741 2 3352 957 2 3425 3734 3 696 3281 74 3 696 2240 2284 1 696 2 123 4829 3 3352 4485 1472 1 3352 2 1057 2676 2 3352 117 3 3352 2110 757 2 3352 1738 4 696 2063 486 4992 5 696 663 219...
output:
2
result:
ok single line: '2'
Test #31:
score: 0
Accepted
time: 24ms
memory: 6808kb
input:
5000 3 2 2852 966 2 3013 741 3 4673 2841 54 2 2788 2793 4 3972 4985 3064 61 2 881 1398 4 3397 3024 3008 2939 2 1202 1987 2 682 3681 2 3621 285 2 1033 3504 2 566 4830 3 3769 3691 954 2 1798 2753 3 1768 3734 555 2 2275 2000 2 4819 1562 2 2256 4448 3 3027 2312 2836 2 3655 4374 2 680 4117 3 3184 1547 16...
output:
2
result:
ok single line: '2'
Test #32:
score: 0
Accepted
time: 19ms
memory: 6824kb
input:
5000 3 2 1705 3546 2 2717 1269 2 1705 2926 1 1705 2 2963 2209 3 1705 2409 1298 2 1705 4644 2 1705 4535 2 39 523 3 655 4219 2994 2 655 4036 2 655 3686 2 655 2965 1 1705 2 1705 4572 3 655 2773 4703 2 655 4276 2 3025 4751 2 1705 1018 2 1705 354 2 655 3348 1 1705 3 1705 741 1652 2 1459 2221 2 3588 350 1...
output:
2
result:
ok single line: '2'
Test #33:
score: 0
Accepted
time: 25ms
memory: 6524kb
input:
5000 3 3 1362 1082 786 2 3599 4179 4 1266 2190 547 4739 2 2747 4567 2 3262 528 2 1833 1694 2 4550 1974 2 1523 4834 2 2329 2542 2 4707 642 3 2834 1858 3947 3 1473 3974 67 5 1036 3652 1233 1318 3514 3 3718 4608 2899 2 2506 3582 2 1722 531 2 2153 1350 4 3209 4531 374 4570 3 1220 4261 1782 3 4385 2990 2...
output:
2
result:
ok single line: '2'
Test #34:
score: -12
Wrong Answer
time: 24ms
memory: 6524kb
input:
5000 3 2 1319 3894 3 2262 4948 1431 2 1865 4172 2 4394 780 2 565 4009 2 3826 3351 3 281 3645 925 2 3798 213 3 467 3992 3265 2 1868 3411 6 4227 4492 2030 3812 1028 2819 3 3710 1929 4412 2 1444 2960 2 4117 520 3 2098 2505 1558 4 3706 4568 4164 1259 5 1947 3367 4745 2918 1521 3 393 3930 3724 2 2028 318...
output:
3
result:
wrong answer 1st lines differ - expected: '2', found: '3'
Subtask #3:
score: 0
Wrong Answer
Test #44:
score: 23
Accepted
time: 19ms
memory: 5856kb
input:
5000 4 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
1
result:
ok single line: '1'
Test #45:
score: -23
Wrong Answer
time: 0ms
memory: 6152kb
input:
20 6 5 16 14 9 18 1 4 15 19 0 7 5 15 8 17 5 12 5 15 16 12 6 13 5 12 18 10 5 9 5 16 4 6 2 8 5 3 16 5 18 8 5 13 17 19 11 1 5 6 2 5 18 10 5 15 4 0 12 11 5 4 14 8 13 17 4 15 9 13 7 5 3 4 14 2 9 5 3 10 19 7 11 5 12 10 17 19 0 5 3 9 1 2 11 5 3 6 0 19 5 5 14 2 18 10 7 5 4 6 8 17 0 5 16 14 13 1 7
output:
4
result:
wrong answer 1st lines differ - expected: '3', found: '4'
Subtask #4:
score: 0
Skipped
Dependency #2:
0%
Subtask #5:
score: 0
Skipped
Dependency #2:
0%