QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#66573#4740. Plan metraHuangHanSheng49 45ms79932kbC++172.4kb2022-12-09 04:39:362022-12-09 04:39:39

詳細信息

Subtask #1:

score: 11
Accepted

Test #1:

score: 11
Accepted
time: 25ms
memory: 75060kb

input:

7
6 6 2 2 1
5 3 5 1 4

output:

TAK
4 1 2
6 1 1
3 7 3
1 5 2
5 2 4
5 7 1

result:

ok good solution

Test #2:

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

input:

10
31 89 20 19 19 20 19 164
70 88 20 20 20 19 20 125

output:

NIE

result:

ok no solution

Test #3:

score: 0
Accepted
time: 17ms
memory: 75144kb

input:

10
57 106 79 12 139 103 103 85
110 53 28 65 98 86 50 117

output:

NIE

result:

ok no solution

Test #4:

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

input:

10
13 62 24 125 13 15 54 94
1 76 14 113 1 1 68 82

output:

NIE

result:

ok no solution

Test #5:

score: 0
Accepted
time: 15ms
memory: 77100kb

input:

10
123 146 139 5 192 80 77 118
97 172 165 31 166 106 51 92

output:

TAK
3 1 146
4 1 139
5 1 5
7 1 80
2 10 97
6 10 166
8 10 51
9 10 92
1 10 26

result:

ok good solution

Test #6:

score: 0
Accepted
time: 25ms
memory: 75136kb

input:

10
112 67 152 16 6 28 1 8
111 82 137 31 21 41 14 7

output:

TAK
3 1 67
5 1 16
6 1 6
4 10 137
1 8 1
8 7 27
8 9 7
9 2 104
9 10 7

result:

ok good solution

Test #7:

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

input:

10
83 108 180 120 114 50 79 132
15 176 112 188 182 118 11 64

output:

TAK
3 1 108
5 1 120
6 1 114
7 1 50
2 10 15
4 10 112
8 10 11
9 10 64
1 10 68

result:

ok good solution

Test #8:

score: 0
Accepted
time: 24ms
memory: 75060kb

input:

10
65 149 150 119 51 90 64 172
66 150 151 120 52 91 65 173

output:

TAK
1 6 51
6 8 13
6 2 14
6 7 39
6 5 68
6 3 98
6 4 99
6 9 121
6 10 52

result:

ok good solution

Test #9:

score: 0
Accepted
time: 25ms
memory: 75040kb

input:

2



output:

TAK
1 2 0

result:

ok good solution

Test #10:

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

input:

10
46 145 46 19 165 20 145 99
47 146 47 112 76 112 146 6

output:

NIE

result:

ok no solution

Test #11:

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

input:

10
4 3 4 150 114 86 99 86
2 3 2 155 118 80 105 80

output:

NIE

result:

ok no solution

Test #12:

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

input:

10
6 7 12 168 171 12 7 7
6 5 14 180 159 14 6 5

output:

NIE

result:

ok no solution

Test #13:

score: 0
Accepted
time: 20ms
memory: 75068kb

input:

10
13 170 28 134 10 117 117 90
98 85 113 49 95 32 32 5

output:

TAK
2 1 13
4 1 28
6 1 10
3 10 85
5 10 49
7 10 32
8 10 32
9 10 5
1 10 85

result:

ok good solution

Test #14:

score: 0
Accepted
time: 20ms
memory: 77064kb

input:

10
90 2 53 53 158 58 1 114
89 1 54 54 161 59 2 111

output:

TAK
6 1 158
9 10 111
1 8 1
8 4 52
8 5 52
8 7 57
8 3 1
3 2 88
3 10 1

result:

ok good solution

Test #15:

score: 0
Accepted
time: 11ms
memory: 75060kb

input:

10
47 2 198 181 29 192 192 2
187 142 58 41 169 52 52 142

output:

TAK
2 1 47
3 1 2
6 1 29
9 1 2
4 10 58
5 10 41
7 10 52
8 10 52
1 10 140

result:

ok good solution

Test #16:

score: 0
Accepted
time: 26ms
memory: 75056kb

input:

10
78 128 140 162 140 110 191 70
79 129 141 163 141 111 192 71

output:

TAK
1 9 70
9 2 8
9 7 40
9 3 58
9 4 70
9 6 70
9 5 92
9 8 121
9 10 71

result:

ok good solution

Test #17:

score: 0
Accepted
time: 28ms
memory: 77264kb

input:

3
1
2

output:

TAK
1 2 1
2 3 2

result:

ok good solution

Subtask #2:

score: 22
Accepted

Dependency #1:

100%
Accepted

Test #18:

score: 22
Accepted
time: 21ms
memory: 75132kb

input:

1000
998 997 996 995 994 993 992 991 990 989 988 987 986 985 984 983 982 981 980 979 978 977 976 975 974 973 972 971 970 969 968 967 966 965 964 963 962 961 960 959 958 957 956 955 954 953 952 951 950 949 948 947 946 945 944 943 942 941 940 939 938 937 936 935 934 933 932 931 930 929 928 927 926 925...

output:

TAK
1 999 1
999 998 1
998 997 1
997 996 1
996 995 1
995 994 1
994 993 1
993 992 1
992 991 1
991 990 1
990 989 1
989 988 1
988 987 1
987 986 1
986 985 1
985 984 1
984 983 1
983 982 1
982 981 1
981 980 1
980 979 1
979 978 1
978 977 1
977 976 1
976 975 1
975 974 1
974 973 1
973 972 1
972 971 1
971 970 ...

result:

ok good solution

Test #19:

score: 0
Accepted
time: 22ms
memory: 77368kb

input:

1000
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 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 55 56 57 58 59 60 61 62 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 92 93 94 95 96 97 98 99 100 101...

output:

TAK
1 2 1
2 3 1
2 4 2
2 5 3
2 6 4
2 7 5
2 8 6
2 9 7
2 10 8
2 11 9
2 12 10
2 13 11
2 14 12
2 15 13
2 16 14
2 17 15
2 18 16
2 19 17
2 20 18
2 21 19
2 22 20
2 23 21
2 24 22
2 25 23
2 26 24
2 27 25
2 28 26
2 29 27
2 30 28
2 31 29
2 32 30
2 33 31
2 34 32
2 35 33
2 36 34
2 37 35
2 38 36
2 39 37
2 40 38
2 ...

result:

ok good solution

Test #20:

score: 0
Accepted
time: 19ms
memory: 75140kb

input:

3000
3246 3738 4685 1539 2140 2026 4814 4815 2059 2686 4692 4403 2701 1596 4878 2470 3194 2272 2171 4120 2654 3349 1842 2046 4360 4529 4792 3250 1741 4766 4337 1559 1601 2362 2295 4463 4987 4119 3847 2272 1522 2882 4556 2484 2864 3002 1446 1772 3089 3092 2562 1461 3630 1879 1899 4881 2334 3189 1794 ...

output:

NIE

result:

ok no solution

Test #21:

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

input:

3000
4130 2457 3399 3125 2758 4911 615 1200 3017 4249 4344 2200 4005 876 4946 976 3067 2029 2158 2667 4183 1380 40 919 3377 2618 3007 1818 1033 227 4422 2971 3208 893 3079 1691 663 4139 2833 1218 4741 2450 789 4493 971 3215 4274 3039 2060 3742 2302 1506 4156 607 773 3151 2661 3913 4082 2956 4454 192...

output:

NIE

result:

ok no solution

Test #22:

score: 0
Accepted
time: 25ms
memory: 77184kb

input:

3000
954 3442 341 795 3138 3391 4895 1174 3801 2933 3695 3388 1743 2942 1572 1029 2173 1438 2270 724 4007 896 2465 4667 3054 249 246 4977 3675 2669 3911 339 2771 984 3399 1237 349 3190 1834 3114 4549 3675 4487 1586 881 2723 677 1290 2979 2710 4746 2994 2524 682 3646 2776 317 4457 2636 2524 3278 465 ...

output:

NIE

result:

ok no solution

Test #23:

score: 0
Accepted
time: 18ms
memory: 77280kb

input:

3000
1236 2492 766 600 2029 4796 1025 4509 3655 4410 1132 3591 2190 3687 3393 1965 4342 3081 4140 2178 476 425 3368 2239 3481 245 548 4122 2637 4282 2385 606 2502 1565 1925 1754 2384 4313 3465 1490 2259 4430 1678 1632 1938 2513 3731 1713 3283 3289 3403 1979 1846 668 2635 3797 4226 4092 614 2677 1977...

output:

TAK
2 1 1236
4 1 766
6 1 2029
8 1 1025
10 1 3655
11 1 4410
14 1 2190
21 1 2178
23 1 425
24 1 3368
25 1 2239
26 1 3481
27 1 245
30 1 2637
33 1 606
36 1 1925
41 1 1490
44 1 1678
46 1 1938
51 1 3289
52 1 3403
56 1 2635
58 1 4226
60 1 614
61 1 2677
63 1 1634
67 1 1093
69 1 845
73 1 2345
75 1 2846
76 1 4...

result:

ok good solution

Test #24:

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

input:

3000
2567 1720 478 391 3422 4790 4949 2339 4239 919 1382 3856 4907 3545 4073 2037 3854 4075 2618 1578 2198 1964 2263 3825 2860 3242 2777 3795 2069 1280 1188 645 2323 4900 4781 4018 4425 4246 4049 2145 2096 1017 3644 3069 3423 3773 3587 4999 4324 1368 677 803 2346 4166 2428 4842 3374 2423 4618 2514 3...

output:

TAK
53 1 803
83 1 2333
99 1 1966
143 1 263
168 1 837
242 1 1472
246 1 1710
357 1 2864
449 1 2672
457 1 766
571 1 1161
573 1 2463
618 1 2852
819 1 1008
823 1 2632
873 1 414
899 1 1220
939 1 363
1020 1 2103
1036 1 2271
1045 1 1715
1069 1 1891
1152 1 2347
1206 1 2771
1216 1 2950
1222 1 1637
1230 1 1929...

result:

ok good solution

Test #25:

score: 0
Accepted
time: 21ms
memory: 75148kb

input:

3000
4989 4334 179 1994 2064 2545 1064 4694 1823 4758 688 3273 875 708 2573 451 2326 4205 4815 1534 3459 2928 3565 3638 1987 4345 1414 4035 2531 1228 1589 3596 4318 3415 4512 2953 2003 2151 1650 4365 1935 4182 1154 1660 1760 1644 2423 1301 3310 2072 3024 1718 4061 1106 2165 4436 2082 1667 3732 260 3...

output:

TAK
1 304 1
304 959 1
304 2292 6
304 2603 14
304 1611 15
304 936 16
304 2710 18
304 2092 19
304 650 20
304 2459 23
304 1790 25
304 1446 26
304 1154 34
304 1407 42
304 1854 50
304 2769 52
304 2471 53
304 2959 73
304 2432 79
304 2500 83
304 2287 86
304 838 87
304 699 89
304 740 95
304 1467 96
304 906 ...

result:

ok good solution

Test #26:

score: 0
Accepted
time: 29ms
memory: 75320kb

input:

3000
1352 2311 3356 3752 3704 2206 3802 2718 1693 3838 2439 1539 2157 2532 3342 2895 2380 1628 3603 3822 1283 4277 3128 4180 2361 3794 3853 4837 3991 4926 2307 4054 3399 3864 1265 2472 4890 1604 1800 4204 4133 4192 4630 3934 4785 3913 1573 4835 2828 3636 2702 2551 4335 2662 4159 2147 3808 3148 3371 ...

output:

TAK
1 2681 1260
2681 1296 9
2681 264 10
2681 1165 13
2681 686 37
2681 1349 46
2681 1744 57
2681 552 60
2681 2011 70
2681 1618 89
2681 2783 103
2681 748 107
2681 101 135
2681 254 167
2681 1917 168
2681 2616 194
2681 1872 204
2681 2116 215
2681 2818 218
2681 564 220
2681 1376 224
2681 2781 229
2681 22...

result:

ok good solution

Test #27:

score: 0
Accepted
time: 21ms
memory: 75216kb

input:

3000
3097 3903 4418 1796 1042 4657 1430 2005 2767 3209 4552 1943 4809 4841 1355 4449 1330 1489 4339 886 749 4199 4558 4731 4947 601 3155 2695 3142 962 3101 2429 737 1891 3333 4856 3247 2016 2097 2504 4465 4420 2036 3511 1433 3773 1896 4490 2307 1489 2123 4623 2931 840 2268 3805 1984 2726 1790 1120 4...

output:

NIE

result:

ok no solution

Test #28:

score: 0
Accepted
time: 17ms
memory: 75152kb

input:

3000
886 2441 1532 1519 993 2071 1533 706 3290 3577 2399 3107 1818 2494 4684 3579 1157 3779 2708 1157 2737 1792 967 3015 2289 2691 4486 2122 2800 2027 3277 4540 3785 1152 4885 2099 1008 2799 3230 1610 3568 4055 2860 1931 1482 4322 3415 3720 3930 3986 2518 1314 1596 1392 469 3657 1438 4159 2898 2654 ...

output:

NIE

result:

ok no solution

Test #29:

score: 0
Accepted
time: 23ms
memory: 75132kb

input:

3000
2696 919 556 3002 1270 4174 2500 353 1352 3944 635 3440 4641 1575 4667 3561 3900 3147 1359 3273 938 829 900 2902 83 1087 302 1109 1910 4061 966 2803 4023 3639 2809 1303 1344 3385 2796 1538 1498 4548 1707 1888 3827 69 2512 557 610 3502 3360 1799 4427 669 3527 2313 4578 4303 2867 1200 1568 488 28...

output:

NIE

result:

ok no solution

Test #30:

score: 0
Accepted
time: 15ms
memory: 75212kb

input:

3000
2853 4599 4265 4267 2411 1064 1784 2058 1150 2720 2494 4060 1681 2671 3694 2359 2568 717 3405 1 1969 791 2362 2547 386 1547 2175 650 3372 4654 2080 2451 2143 397 3823 339 1073 3915 1218 905 3584 1340 901 681 240 2919 2433 4199 4842 2488 3026 724 3660 1325 265 4696 2023 4322 4057 2231 2640 4469 ...

output:

TAK
1 21 1
21 856 3
21 620 4
21 2601 7
21 156 8
21 2125 9
21 525 10
21 1563 12
21 1344 16
21 995 23
21 2163 25
21 1804 27
21 2887 29
21 1865 30
21 739 32
21 101 35
21 1423 36
21 2377 37
21 199 38
21 1736 41
21 2129 42
21 2584 45
21 1652 48
21 2204 49
21 1691 50
21 532 54
21 2484 55
21 2303 56
21 268...

result:

ok good solution

Test #31:

score: 0
Accepted
time: 22ms
memory: 77372kb

input:

3000
2218 4876 1974 1767 390 3598 1346 2423 981 4265 1477 3160 1900 2063 4806 624 2391 4129 1166 3586 3094 1018 1384 2665 3668 2680 3722 3123 4195 3774 3897 1755 4422 1528 3473 3656 2016 992 4424 582 1797 1852 4493 3604 2722 1591 2900 2124 1375 4122 284 3011 4290 3482 4840 1712 2916 684 1624 1356 47...

output:

TAK
35 1 1528
59 1 684
60 1 1624
67 1 522
77 1 633
78 1 1562
81 1 2029
99 1 3417
109 1 1589
119 1 623
150 1 1018
153 1 2043
155 1 1209
156 1 841
163 1 2546
180 1 3319
187 1 3282
193 1 694
196 1 2405
205 1 3587
213 1 1448
247 1 1544
251 1 2502
254 1 559
283 1 1410
284 1 363
287 1 632
322 1 2592
368 1...

result:

ok good solution

Test #32:

score: 0
Accepted
time: 20ms
memory: 75212kb

input:

3000
1091 3360 3940 2706 3309 1955 1031 4529 3713 3820 3280 1916 952 4104 262 4281 3753 3446 1426 3135 3016 50 4491 3646 1717 3391 3677 2804 3046 3658 342 4348 4900 3701 1141 4942 907 4024 1412 1922 2071 4306 3746 1073 2301 517 2824 3500 1580 105 2728 3224 4806 3607 4640 3007 4097 3525 2260 28 74 13...

output:

TAK
1 483 1
483 1362 1
483 1936 3
483 2086 5
483 2594 7
483 1611 8
483 1983 11
483 476 13
483 2042 15
483 2548 18
483 1082 20
483 2241 21
483 2308 22
483 408 23
483 2407 25
483 2157 26
483 61 27
483 2692 29
483 2177 30
483 2679 34
483 1737 36
483 2717 37
483 236 41
483 397 42
483 222 44
483 525 45
4...

result:

ok good solution

Test #33:

score: 0
Accepted
time: 20ms
memory: 75280kb

input:

3000
3066 4794 1434 2322 1630 2913 1767 2035 4692 1441 3958 1787 2971 4301 3880 2889 3648 3292 3412 3012 2637 3888 4310 4986 4854 1983 2463 3127 4270 4277 3117 4782 4979 4226 3572 2153 4973 4226 2459 2092 4055 4711 1362 4527 1967 4794 1576 4563 3917 3941 2122 2808 1769 2958 4199 1431 4698 4117 4978 ...

output:

TAK
1 1445 1270
1445 1558 35
1445 2254 40
1445 2218 289
1445 1023 379
1445 2087 898
1445 1748 1613
1445 1679 1849
1445 2182 1926
1445 823 2505
1445 2993 2683
1445 848 2937
1445 1104 3083
1445 757 3387
1445 1041 3675
1445 2733 1
2733 1472 86
2733 2884 118
2733 2703 260
2733 2347 289
2733 2089 295
273...

result:

ok good solution

Test #34:

score: 0
Accepted
time: 11ms
memory: 75216kb

input:

3000
3007 4339 2713 1682 3269 896 4912 1719 4017 2821 4716 4834 3914 2774 4564 1041 3359 1294 2362 3216 811 4452 4433 4144 1481 1748 3833 1420 1847 1424 1051 2678 2486 2506 2275 2397 3745 612 2430 3651 2980 3630 2386 3229 4982 3356 4081 4489 2604 4456 3572 1906 2670 3437 4940 2119 4182 4332 2324 368...

output:

NIE

result:

ok no solution

Test #35:

score: 0
Accepted
time: 15ms
memory: 75124kb

input:

3000
2113 2877 3332 1103 4221 1402 4988 3090 4447 3216 1214 2798 955 3564 3217 1640 3071 535 3509 1280 2014 2438 4628 1313 4929 3109 2404 4673 3314 1876 2131 4980 1943 2809 3748 3561 3790 1597 1120 2025 2927 2952 3810 1676 2214 3217 2319 1247 4407 2023 3757 1276 983 3849 2859 4187 2397 1631 1041 341...

output:

NIE

result:

ok no solution

Test #36:

score: 0
Accepted
time: 29ms
memory: 77124kb

input:

3000
1941 4646 2168 786 3079 4598 455 2861 4243 3087 3829 1626 2823 2402 4194 1680 3570 2198 1509 269 4882 99 3402 90 847 4219 3347 1955 757 88 134 2186 363 683 4604 1303 4488 2916 4352 551 2002 2107 4420 4418 4068 4754 3143 449 2727 2952 2414 3510 2293 2404 1223 1883 2098 2705 2223 3573 1742 4892 8...

output:

NIE

result:

ok no solution

Test #37:

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

input:

3000
4823 3370 3546 689 4392 2253 1309 1492 3406 3625 1540 1996 4594 1050 1342 2511 1137 1314 3871 693 1583 4453 2136 4567 2421 3968 956 4538 2083 534 537 1435 4836 3214 4443 607 3882 2646 171 1212 3325 4061 4967 4678 1267 3035 542 748 1552 8 851 2456 1224 210 2791 3160 257 4498 2664 2658 1450 3532 ...

output:

TAK
2 1 4823
4 1 3546
7 1 2253
9 1 1492
10 1 3406
13 1 1996
14 1 4594
17 1 2511
18 1 1137
19 1 1314
21 1 693
22 1 1583
23 1 4453
24 1 2136
25 1 4567
26 1 2421
28 1 956
29 1 4538
30 1 2083
31 1 534
34 1 4836
36 1 4443
39 1 2646
40 1 171
41 1 1212
42 1 3325
44 1 4967
45 1 4678
46 1 1267
47 1 3035
49 1...

result:

ok good solution

Test #38:

score: 0
Accepted
time: 22ms
memory: 75292kb

input:

3000
3332 756 2055 1288 1561 1514 2953 536 3784 2353 423 4776 2334 2892 2112 1377 4588 1432 999 3987 3063 1186 945 696 1028 1459 3404 147 4055 467 721 3838 2162 793 3748 3218 1458 2074 3532 2710 768 452 2784 1080 4603 953 1112 4307 2720 1891 2228 726 2429 1093 1606 2130 4564 1780 2546 1829 1373 1104...

output:

TAK
3 1 756
4 1 2055
5 1 1288
9 1 536
11 1 2353
14 1 2334
21 1 3987
29 1 147
38 1 1458
39 1 2074
50 1 2720
58 1 4564
67 1 1601
72 1 2749
74 1 4364
75 1 1145
80 1 862
82 1 2125
85 1 1056
87 1 177
94 1 2679
95 1 4480
103 1 2448
111 1 4469
115 1 1068
116 1 4486
118 1 4156
123 1 1104
124 1 573
129 1 150...

result:

ok good solution

Test #39:

score: 0
Accepted
time: 30ms
memory: 77348kb

input:

3000
610 1799 1393 878 3099 1418 555 4169 1562 4823 4392 1525 2214 4168 975 4890 2034 1330 1266 946 2075 307 1229 2186 2106 473 3813 1702 309 1364 1328 956 906 2762 2254 4157 1434 2144 4442 3727 645 231 1985 4331 1625 544 602 1530 820 2125 909 1635 331 2216 1040 2794 1910 1764 4207 37 4032 4231 3354...

output:

TAK
2 1 610
3 1 1799
4 1 1393
5 1 878
7 1 1418
8 1 555
10 1 1562
13 1 1525
14 1 2214
16 1 975
18 1 2034
19 1 1330
20 1 1266
21 1 946
22 1 2075
23 1 307
24 1 1229
25 1 2186
26 1 2106
27 1 473
29 1 1702
30 1 309
31 1 1364
32 1 1328
33 1 956
34 1 906
36 1 2254
38 1 1434
39 1 2144
42 1 645
43 1 231
44 1...

result:

ok good solution

Test #40:

score: 0
Accepted
time: 23ms
memory: 77280kb

input:

3000
4392 2140 1762 1461 3944 3373 4608 2697 4508 3925 2016 1302 1448 1844 3854 4939 4992 2464 2034 3218 2114 1842 4347 3542 2030 4337 4016 3264 3751 1853 4686 1828 4083 4348 2692 4589 4107 3632 3108 2720 3526 3300 2029 3304 4522 1722 3600 4343 2664 3156 4156 1738 2972 3083 2460 2676 4999 1868 4196 ...

output:

TAK
1 1220 1270
1220 1089 3
1220 1168 7
1220 1443 11
1220 2153 12
1220 1480 43
1220 184 74
1220 1033 75
1220 111 92
1220 2415 133
1220 440 170
1220 1410 181
1220 2579 199
1220 936 208
1220 91 216
1220 541 220
1220 1183 222
1220 1956 235
1220 1907 248
1220 1555 267
1220 703 277
1220 2434 289
1220 281...

result:

ok good solution

Test #41:

score: 0
Accepted
time: 16ms
memory: 77256kb

input:

3000
3776 3020 74 3836 4635 2332 3602 1143 1563 561 2317 1552 3531 1627 1560 3621 4104 4827 4065 1455 1113 4256 3436 107 3547 4420 1826 3772 4563 3927 4787 2141 3872 2726 607 2231 741 1769 4393 1596 2722 3962 3138 2631 4816 2958 4416 1539 1622 4220 1251 4873 4258 1589 3411 3298 2222 3702 1461 899 62...

output:

NIE

result:

ok no solution

Test #42:

score: 0
Accepted
time: 14ms
memory: 77272kb

input:

3000
3417 1286 2330 2910 1263 1904 2737 441 2043 2538 2191 3631 735 4281 1323 23 2407 2205 2405 2006 1822 2649 2622 526 1686 404 2569 3775 1194 3323 3357 2468 2466 374 1775 2699 1300 4548 2725 2306 4895 3011 4969 3321 1057 1716 3863 3360 3212 1994 4246 1212 644 3247 1964 962 2590 2942 818 2489 4223 ...

output:

NIE

result:

ok no solution

Test #43:

score: 0
Accepted
time: 14ms
memory: 75136kb

input:

3000
2126 1360 2131 843 4339 3597 4621 4533 4809 1878 4303 4777 2153 263 4424 1155 3541 1201 902 718 1277 2918 3751 2585 706 507 3311 4920 1164 1080 3461 4868 970 1274 625 3964 511 2880 2594 4673 3685 4602 510 1459 4702 1565 94 3545 255 3943 591 327 18 4823 1373 4165 1833 4489 1202 717 2532 4699 142...

output:

NIE

result:

ok no solution

Test #44:

score: 0
Accepted
time: 19ms
memory: 75232kb

input:

3000
1149 3550 1728 2850 1560 200 3630 4848 2568 1394 3044 2947 2576 589 2523 4333 3635 1043 3508 580 2380 2902 4838 4531 1484 4328 654 4418 2761 506 1862 498 2891 4653 2062 4698 4399 1389 1167 62 2304 329 1904 1142 2031 3770 3005 4208 668 453 468 2324 1741 823 3262 4403 1424 2565 4335 2592 3324 802...

output:

TAK
4 1 1728
5 1 2850
12 1 3044
16 1 2523
17 1 4333
18 1 3635
19 1 1043
24 1 4838
26 1 1484
28 1 654
29 1 4418
34 1 2891
36 1 2062
38 1 4399
39 1 1389
43 1 329
47 1 3770
48 1 3005
49 1 4208
50 1 668
51 1 453
52 1 468
53 1 2324
57 1 4403
58 1 1424
59 1 2565
61 1 2592
62 1 3324
63 1 802
65 1 2832
66 1...

result:

ok good solution

Test #45:

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

input:

3000
1635 282 203 1698 4542 4581 66 4702 4313 1436 2957 1820 4475 3991 1646 864 1367 4202 2545 1317 2712 1529 1371 370 1656 1932 654 3311 372 3257 844 4365 2111 2359 1379 405 3050 2395 29 3467 3429 3417 554 2911 2615 3735 2696 4529 2573 4394 3925 3605 3212 2655 469 1981 465 1141 1791 2303 4758 333 1...

output:

TAK
4 1 203
30 1 372
35 1 2359
48 1 2696
80 1 1552
101 1 3274
114 1 2620
139 1 3690
140 1 3572
149 1 2926
154 1 4269
163 1 142
170 1 3318
172 1 3562
201 1 4193
291 1 1391
293 1 322
295 1 856
318 1 3918
328 1 445
381 1 2732
407 1 465
430 1 1996
469 1 381
474 1 64
516 1 4112
532 1 601
563 1 687
578 1 ...

result:

ok good solution

Test #46:

score: 0
Accepted
time: 40ms
memory: 77208kb

input:

3000
3095 3686 2303 4864 4525 4973 686 2608 2702 3043 1530 398 971 2975 249 3931 1914 2949 2100 1211 636 270 735 172 799 1903 4870 2863 504 1980 1613 2760 2753 96 3261 2262 2965 1590 3374 2417 618 1414 3734 2313 4838 855 3014 403 4064 405 2692 4503 4068 3962 255 2631 4061 2216 1937 2683 1290 590 545...

output:

TAK
8 1 686
9 1 2608
10 1 2702
12 1 1530
13 1 398
14 1 971
15 1 2975
16 1 249
18 1 1914
20 1 2100
21 1 1211
22 1 636
23 1 270
24 1 735
25 1 172
26 1 799
27 1 1903
30 1 504
32 1 1613
35 1 96
39 1 1590
41 1 2417
42 1 618
43 1 1414
47 1 855
48 1 3014
49 1 403
51 1 405
56 1 255
61 1 2683
62 1 1290
63 1 ...

result:

ok good solution

Test #47:

score: 0
Accepted
time: 18ms
memory: 77356kb

input:

3000
3150 1836 3172 4068 4876 2943 3457 2989 2031 4298 3147 2187 3949 1874 3444 3509 3477 3857 4473 4688 4270 3254 2633 2539 2586 2095 4295 2717 2061 3175 2604 3459 3514 2929 4280 2896 4154 4187 4400 1897 4733 1450 2311 2971 4025 2366 3119 1779 1624 3743 2393 2767 4341 3316 1467 2982 3749 3553 3430 ...

output:

TAK
1 2891 1321
2891 1164 1
2891 1758 9
2891 2627 15
2891 1264 22
2891 306 32
2891 637 54
2891 443 69
2891 2646 76
2891 2970 103
2891 2846 116
2891 191 126
2891 865 127
2891 2097 137
2891 56 146
2891 2874 148
2891 2661 156
2891 1036 169
2891 238 176
2891 1196 181
2891 578 182
2891 616 196
2891 1110 ...

result:

ok good solution

Subtask #3:

score: 16
Accepted

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Test #48:

score: 16
Accepted
time: 25ms
memory: 77188kb

input:

3000
33632 494127 696342 350424 494687 244029 34205 358600 33589 33688 33654 363547 917716 709668 34132 209516 647123 33932 459553 338587 344502 34173 33962 959639 186658 432587 751908 196121 831694 938534 375210 34215 33945 496720 944120 717068 359228 823700 795101 264198 894106 166421 878905 56096...

output:

NIE

result:

ok no solution

Test #49:

score: 0
Accepted
time: 17ms
memory: 75112kb

input:

3000
719501 190371 419469 530974 227226 585792 231123 604640 810638 945824 81162 234692 81417 470485 81514 904536 160555 81120 458883 833590 292427 298463 696428 991251 803836 290845 81271 164910 812817 311546 346303 182445 988478 81452 141870 399912 573781 113364 81366 707078 81447 579746 652421 74...

output:

NIE

result:

ok no solution

Test #50:

score: 0
Accepted
time: 21ms
memory: 77396kb

input:

3000
33367 117225 986863 489993 459134 848608 659883 682415 386653 418414 25671 596199 603604 686775 61167 861049 479739 998241 526134 349446 175511 428454 577920 180611 399767 519572 413504 675392 691762 456302 401104 641737 992570 216016 396301 671015 937784 490764 151444 958516 175964 611128 5533...

output:

NIE

result:

ok no solution

Test #51:

score: 0
Accepted
time: 30ms
memory: 75180kb

input:

3000
260266 727761 367878 933399 741131 526721 356038 469953 595663 297117 360534 710090 328255 86691 112505 523756 449413 409669 321665 538883 631287 870029 374437 621113 243200 488734 528312 245165 63888 469460 162819 286313 659751 375112 725042 852767 50740 335486 612512 698770 344877 461833 3401...

output:

TAK
2 1 260266
8 1 356038
9 1 469953
15 1 86691
16 1 112505
17 1 523756
18 1 449413
21 1 538883
22 1 631287
25 1 621113
30 1 63888
32 1 162819
35 1 375112
36 1 725042
38 1 50740
39 1 335486
41 1 698770
42 1 344877
43 1 461833
44 1 340107
45 1 683660
46 1 450369
47 1 684461
50 1 592525
54 1 198256
56...

result:

ok good solution

Test #52:

score: 0
Accepted
time: 32ms
memory: 75180kb

input:

3000
990602 644534 718130 852792 816707 576523 58111 482057 102335 439369 73379 670012 929674 479443 361759 70928 79563 613769 853718 167957 655511 263428 76069 534776 73859 214474 58816 163198 518911 871410 518783 482805 378241 481322 213457 58326 434589 506037 323789 931785 657187 697710 40451 325...

output:

TAK
3 1 644534
4 1 718130
5 1 852792
7 1 576523
10 1 102335
12 1 73379
16 1 361759
21 1 167957
23 1 263428
24 1 76069
28 1 58816
33 1 482805
36 1 213457
39 1 506037
44 1 40451
47 1 375954
49 1 696956
55 1 546171
57 1 765537
63 1 477725
64 1 328015
65 1 171123
73 1 142518
75 1 60262
80 1 52797
87 1 3...

result:

ok good solution

Test #53:

score: 0
Accepted
time: 34ms
memory: 75420kb

input:

3000
123371 312195 835995 149637 799487 170772 195292 648627 476326 803490 674499 244504 429531 806106 255448 371496 627676 780092 473422 303011 943356 44364 430413 893362 706897 367434 126526 297689 257900 841409 228421 592559 817799 53260 349853 208307 3859 708783 827617 707957 652158 62545 147155...

output:

TAK
2 1 123371
5 1 149637
7 1 170772
9 1 648627
10 1 476326
12 1 674499
16 1 255448
17 1 371496
19 1 780092
20 1 473422
23 1 44364
24 1 430413
27 1 367434
28 1 126526
32 1 228421
34 1 817799
35 1 53260
36 1 349853
37 1 208307
38 1 3859
40 1 827617
42 1 652158
43 1 62545
44 1 147155
45 1 22413
46 1 3...

result:

ok good solution

Test #54:

score: 0
Accepted
time: 20ms
memory: 75208kb

input:

3000
704276 595819 568590 836740 981560 800902 584618 694682 933504 974612 414162 378635 951690 459865 651877 937255 771192 697635 745645 614206 558771 409173 874112 760798 801123 668957 436923 787718 511406 483169 378210 847039 812786 739322 999151 816301 783567 639619 903009 667105 988812 488588 4...

output:

TAK
1 1474 363709
1474 2028 1
2028 1820 437
2028 2000 2585
2028 2372 4314
2028 392 5990
2028 489 7659
2028 2652 10056
2028 1071 10500
2028 1985 12133
2028 2510 12932
2028 2718 13850
2028 1026 16602
2028 189 16826
2028 303 22732
2028 324 25922
2028 369 26573
2028 800 29383
2028 1193 29532
2028 2943 3...

result:

ok good solution

Test #55:

score: 0
Accepted
time: 19ms
memory: 75140kb

input:

3
1000000
1000000

output:

TAK
1 2 1000000
2 3 1000000

result:

ok good solution

Test #56:

score: 0
Accepted
time: 16ms
memory: 75264kb

input:

3000
27101 27983 193378 657093 26818 582247 27954 896701 26832 26964 27154 27378 897450 27446 28201 26712 27074 27462 26668 576438 27163 27578 27786 27207 728499 27651 648949 967139 27257 26891 28024 28232 27404 27067 476498 239642 27530 27823 27523 26797 26811 953213 405305 27636 293694 665456 3310...

output:

NIE

result:

ok no solution

Test #57:

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

input:

3000
537112 103838 832868 830790 677585 659891 740326 252361 686559 651870 326268 145324 136382 298958 219533 355420 245302 601455 417307 926830 602452 599847 648943 139897 531894 756503 978725 909009 409585 916592 517693 661310 221309 741779 837024 238513 929589 808890 512579 363468 498002 809345 8...

output:

NIE

result:

ok no solution

Test #58:

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

input:

3000
991921 585293 542720 18525 480227 709619 847291 105630 565857 799501 308455 491502 624191 767273 671319 421201 642691 106134 400479 63986 235649 212633 325475 235877 433366 426394 334065 642273 426190 41017 507218 348107 600047 423854 976051 447957 857087 461509 916016 580192 980835 955627 8198...

output:

NIE

result:

ok no solution

Test #59:

score: 0
Accepted
time: 36ms
memory: 77268kb

input:

3000
697884 570622 241819 900495 464741 78272 953627 926656 159040 748364 675506 244571 359302 431515 168816 131152 97687 385149 404339 468702 315173 293798 578602 493224 648731 217412 472269 43894 308667 407331 224954 941937 677131 692419 252121 283252 270771 531187 751486 446050 761826 795926 4426...

output:

TAK
6 1 464741
7 1 78272
10 1 159040
11 1 748364
12 1 675506
16 1 168816
17 1 131152
18 1 97687
19 1 385149
20 1 404339
21 1 468702
23 1 293798
25 1 493224
26 1 648731
28 1 472269
29 1 43894
31 1 407331
32 1 224954
34 1 677131
39 1 531187
41 1 446050
42 1 761826
44 1 442627
46 1 699275
47 1 435069
4...

result:

ok good solution

Test #60:

score: 0
Accepted
time: 28ms
memory: 75228kb

input:

3000
307838 358602 49735 302647 593319 117587 328601 987296 267770 907439 674952 832723 93519 201538 968152 876115 238734 867922 360015 411639 919148 378541 45812 216062 486655 345283 617897 951353 925030 562132 292774 128846 642902 71545 426038 21725 973771 581790 163196 449900 459681 8258 776928 3...

output:

TAK
8 1 328601
26 1 486655
27 1 345283
97 1 239450
107 1 313409
128 1 814275
153 1 104000
167 1 558934
199 1 336917
312 1 389603
430 1 55851
437 1 562647
444 1 83862
470 1 264789
475 1 797873
500 1 119060
519 1 206631
617 1 92803
704 1 5648
709 1 6242
764 1 431799
809 1 948134
874 1 522464
881 1 637...

result:

ok good solution

Test #61:

score: 0
Accepted
time: 26ms
memory: 77340kb

input:

3000
166414 871840 137934 886504 196581 562439 801561 565428 728076 760260 181697 595415 283545 999940 62920 444518 822135 50733 749639 335008 839611 426682 735978 814746 313373 813828 938298 756292 801277 475252 748124 324149 475297 820802 903704 485954 224145 768084 29558 423821 956820 519682 3564...

output:

TAK
13 1 595415
19 1 50733
22 1 839611
23 1 426682
26 1 313373
40 1 29558
41 1 423821
42 1 956820
63 1 727877
82 1 140780
84 1 715259
89 1 321234
93 1 517925
95 1 205834
101 1 499054
102 1 956053
103 1 82825
120 1 877691
124 1 299974
128 1 604408
130 1 306303
132 1 754278
136 1 49506
140 1 249248
14...

result:

ok good solution

Test #62:

score: 0
Accepted
time: 20ms
memory: 75316kb

input:

3000
721450 597466 646554 601431 855464 782681 963513 875992 785906 383940 442776 879631 384499 969947 389826 637712 721693 811372 738039 683456 737871 467574 924234 535092 719108 861836 840676 723386 860907 850142 671514 882765 366681 851885 557551 846579 942567 647968 909603 704946 499304 429153 9...

output:

TAK
1 1162 285278
1162 1422 632
1162 2104 870
1162 2826 3856
1162 464 4584
1162 239 5027
1162 1679 5336
1162 2341 7014
1162 1627 7106
1162 2676 7151
1162 235 10559
1162 2818 18540
1162 2737 20223
1162 2702 21645
1162 1099 21674
1162 996 22924
1162 2569 23635
1162 170 25875
1162 817 27275
1162 264 30...

result:

ok good solution

Test #63:

score: 0
Accepted
time: 18ms
memory: 77188kb

input:

3000
473738 815133 745850 184285 575674 644352 378025 554473 184277 184293 445661 702130 925518 872029 619452 535894 483933 447368 376325 548345 240584 268543 888464 953777 376892 726063 641865 475367 721552 538018 633708 462743 390489 553370 382971 859037 733927 592313 495940 578653 724130 342469 7...

output:

NIE

result:

ok no solution

Test #64:

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

input:

3000
113146 205398 480860 411505 620634 358238 615045 403557 887039 201203 570311 176484 664526 991741 680592 405209 120459 88699 948415 173428 81742 388006 298591 513129 574518 808667 439161 227583 919128 519576 629930 672354 238459 226005 801315 814560 396280 998117 273814 935845 548366 846275 860...

output:

NIE

result:

ok no solution

Test #65:

score: 0
Accepted
time: 16ms
memory: 77128kb

input:

3000
892289 178934 632248 7584 672665 790021 713633 242070 512707 142322 847647 272840 990371 770894 651491 447478 295050 594637 739718 102518 908490 702008 745317 596945 526418 22343 560051 893064 299592 858019 630089 390792 82409 600030 672327 235410 264827 777043 148216 215347 157613 862174 13251...

output:

NIE

result:

ok no solution

Test #66:

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

input:

3000
85497 782516 440617 122737 498723 530740 618744 669858 803431 384680 924773 121723 471502 578003 48506 991262 618935 794554 550952 687780 280595 698132 795442 968818 416209 612154 964367 400849 581175 456465 805944 907680 680473 75523 935021 733692 141130 973798 91801 243824 421696 243208 48266...

output:

TAK
5 1 122737
6 1 498723
8 1 618744
9 1 669858
10 1 803431
11 1 384680
12 1 924773
13 1 121723
14 1 471502
15 1 578003
16 1 48506
17 1 991262
18 1 618935
19 1 794554
20 1 550952
21 1 687780
23 1 698132
26 1 416209
27 1 612154
28 1 964367
29 1 400849
31 1 456465
32 1 805944
33 1 907680
34 1 680473
3...

result:

ok good solution

Test #67:

score: 0
Accepted
time: 37ms
memory: 75180kb

input:

3000
331569 320335 732683 330711 328048 151764 38202 8416 154487 413668 61405 711786 963841 783778 26951 201366 603171 68679 730606 400397 247463 767459 12777 987072 369773 797826 299662 60926 96047 764493 878790 877841 541952 88643 521699 525689 690768 826397 721998 347879 80796 324516 874650 10658...

output:

TAK
3 1 320335
8 1 38202
11 1 413668
17 1 201366
20 1 730606
22 1 247463
30 1 96047
44 1 874650
47 1 700552
48 1 305760
50 1 400350
54 1 700824
55 1 383786
58 1 742584
59 1 262388
65 1 368004
67 1 28212
70 1 424709
72 1 470139
73 1 332300
74 1 310823
75 1 546651
76 1 682605
85 1 7804
89 1 627275
94 ...

result:

ok good solution

Test #68:

score: 0
Accepted
time: 27ms
memory: 75216kb

input:

3000
548182 740314 631064 192542 164200 531146 106418 983122 974332 129868 698936 615288 777559 321404 253908 383134 523947 416670 308886 341321 476121 70281 718792 629602 28162 601366 451204 269989 545667 751947 826307 446280 527548 26727 398541 587717 635146 703519 624210 375574 130718 235403 7811...

output:

TAK
2 1 548182
3 1 740314
5 1 192542
6 1 164200
7 1 531146
8 1 106418
11 1 129868
12 1 698936
15 1 321404
17 1 383134
18 1 523947
19 1 416670
20 1 308886
23 1 70281
26 1 28162
27 1 601366
28 1 451204
29 1 269989
31 1 751947
35 1 26727
37 1 587717
41 1 375574
42 1 130718
43 1 235403
46 1 403667
47 1 ...

result:

ok good solution

Test #69:

score: 0
Accepted
time: 22ms
memory: 75240kb

input:

3000
742646 897641 802380 899948 905956 639096 703135 757737 754345 317900 774107 395408 490989 658133 573512 889024 983515 324485 814191 348011 741582 831684 961240 712121 373360 959766 842411 363278 831111 988393 671162 457602 565366 451740 366471 601336 824537 693783 325012 376500 977593 819894 4...

output:

TAK
1 264 302278
264 1096 954
264 272 3466
264 1556 4276
264 2971 5221
264 1063 5636
264 2638 9818
264 2765 10141
264 987 11337
264 2277 18308
264 182 20385
264 2218 20566
264 2123 22486
264 40 22734
264 2479 26956
264 2589 27787
264 548 30954
264 1222 33734
264 1130 33881
264 579 36091
264 2157 423...

result:

ok good solution

Subtask #4:

score: 0
Time Limit Exceeded

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Dependency #3:

100%
Accepted

Test #70:

score: 33
Accepted
time: 31ms
memory: 79932kb

input:

100000
881920 696247 189234 495545 188761 373014 199791 168987 191605 201736 907451 427051 356912 461898 536499 170776 378997 172047 774231 799185 996450 599835 288996 192846 371945 823647 983555 978285 739473 852317 198417 938871 181975 194608 485685 201973 167902 898743 186129 584228 407225 358850...

output:

NIE

result:

ok no solution

Test #71:

score: 0
Accepted
time: 31ms
memory: 76540kb

input:

100000
92316 769709 343358 629401 604167 293907 687931 521411 31820 186019 563967 339580 348256 388924 820250 418704 945127 257027 422694 655287 839717 728729 650694 279172 219655 828513 194351 322775 429687 722729 571860 153908 694417 792667 545406 206590 597060 269760 756100 200081 225850 733911 7...

output:

NIE

result:

ok no solution

Test #72:

score: 0
Accepted
time: 32ms
memory: 77564kb

input:

100000
801047 906028 898965 907497 29765 205398 956 961001 60261 828933 343075 88720 194743 781037 214480 56958 231138 209707 10462 957788 330213 119347 21804 81978 889203 335634 330146 348271 269644 21194 865382 145646 164454 90253 137428 147526 116217 209926 842296 88578 522181 714103 413389 55975...

output:

NIE

result:

ok no solution

Test #73:

score: -33
Time Limit Exceeded

input:

100000
832000 61235 836159 888831 751978 30532 906985 393271 747372 290700 828247 35630 500107 403962 832660 635064 900713 672614 478665 747849 303240 116923 478840 821191 191303 978515 906506 504491 456986 783479 866177 49871 216678 296084 672984 416638 396597 526234 670155 896511 242650 469235 706...

output:

TAK
2 1 832000
3 1 61235
4 1 836159
5 1 888831
6 1 751978
7 1 30532
9 1 393271
10 1 747372
12 1 828247
13 1 35630
14 1 500107
15 1 403962
17 1 635064
18 1 900713
19 1 672614
23 1 116923
28 1 906506
29 1 504491
30 1 456986
31 1 783479
32 1 866177
33 1 49871
34 1 216678
35 1 296084
36 1 672984
37 1 41...

result:


Subtask #5:

score: 0
Skipped

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Dependency #3:

100%
Accepted

Dependency #4:

0%