QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#330386 | #6537. One, Two, Three | mfeitveer | AC ✓ | 58ms | 27640kb | C++14 | 3.3kb | 2024-02-17 15:04:44 | 2024-02-17 15:04:45 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
#define x first
#define y second
// #define int long long
#define mp(x, y) make_pair(x, y)
#define eb(...) emplace_back(__VA_ARGS__)
#define fro(i, x, y) for(int i = (x); i <= (y); i++)
#define pre(i, x, y) for(int i = (x); i >= (y); i--)
inline void JYFILE19();
typedef long long i64;
typedef pair<int, int> PII;
bool ST;
const int N = 1e6 + 10;
const int mod = 998244353;
int n, m, a[N], b[N], vs[N], ds[N], pr[N], sf[N];
queue<int> n1;
queue<PII> n2;
queue<tuple<int, int, int>> n3;
signed main() {
JYFILE19();
cin >> n;
fro(i, 1, n) {
cin >> a[i], b[i] = a[i];
}
int it = n;
fro(i, 1, n) {
if(a[i] == 3) {
while(it > i && a[it] != 1) {
it--;
}
if(i == it) break;
swap(a[it], a[i]);
vs[i] = vs[it] = 1;
}
}
fro(i, 1, n) {
if(a[i] == 1) {
n1.emplace(i);
}
if(a[i] == 2) {
if(n1.size()) {
n2.emplace(n1.front(), i);
n1.pop();
}
}
if(a[i] == 3) {
if(n2.size()) {
n3.emplace(n2.front().x, n2.front().y, i);
n2.pop();
}
}
}
cout << n3.size() << "\n";
vector<tuple<int, int, int>> num1, num2;
while(n3.empty() == 0) {
int x, y, z;
tie(x, y, z) = n3.front(); n3.pop();
if((vs[x] ^ vs[z]) == 0) {
cout << x - 1 << " " << y - 1 << " " << z - 1 << "\n";
ds[x] = ds[y] = ds[z] = 1;
}
else {
int id = b[x], ax, ay, az;
if(vs[x] == 0) id = a[x];
if(vs[z] == 0) id = a[z];
if(id == 1) {
if(num2.empty()) {
num1.eb(x, y, z);
goto ed;
}
else {
tie(ax, ay, az) = num2.back();
num2.pop_back();
}
}
else {
if(num1.empty()) {
num2.eb(x, y, z);
goto ed;
}
else {
tie(ax, ay, az) = num1.back();
num1.pop_back();
}
}
if(x < ay) {
cout << ax - 1 << " " << y - 1 << " " << z - 1 << "\n";
cout << x - 1 << " " << ay - 1 << " " << az - 1 << "\n";
}
else {
if(az < y) {
cout << ax - 1 << " " << ay - 1 << " " << x - 1 << "\n";
cout << az - 1 << " " << y - 1 << " " << z - 1 << "\n";
}
else {
cout << ax - 1 << " " << ay - 1 << " " << z - 1 << "\n";
cout << x - 1 << " " << y - 1 << " " << az - 1 << "\n";
}
}
ds[ax] = ds[ay] = ds[az] = ds[x] = ds[y] = ds[z] = 1;
ed:;
}
}
int id;
if(num1.size()) {
id = 3;
for(auto i : num1) {
int x, y, z;
tie(x, y, z) = i;
ds[y] = 2, pr[y] = x, sf[y] = z;
}
}
if(num2.size()) {
id = 1;
for(auto i : num2) {
int x, y, z;
tie(x, y, z) = i;
ds[y] = 2, pr[y] = x, sf[y] = z;
}
}
queue<PII> q;
fro(i, 1, n) {
if(b[i] == id && !ds[i]) {
if(q.empty() || q.front().y == 1) {
q.emplace(i, 1);
}
else if(!q.empty()) {
int x = q.front().x;
cout << pr[x] - 1 << " " << x - 1 << " " << i - 1 << "\n";
q.pop();
}
}
if(ds[i] == 2) {
if(q.empty() || q.front().y == 2) {
q.emplace(i, 2);
}
else if(!q.empty()) {
int x = q.front().x;
cout << x - 1 << " " << i - 1 << " " << sf[i] - 1 << "\n";
q.pop();
}
}
}
return 0;
}
bool ED;
inline void JYFILE19() {
// freopen("", "r", stdin);
// freopen("", "w", stdout);
ios::sync_with_stdio(0), cin.tie(0);
double MIB = fabs((&ED-&ST)/1048576.), LIM = 32;
cerr << "MEMORY: " << MIB << endl, assert(MIB<=LIM);
}
这程序好像有点Bug,我给组数据试试?
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 2ms
memory: 12036kb
input:
6 3 1 2 2 3 1
output:
2 0 3 5 1 2 4
result:
ok count=2
Test #2:
score: 0
Accepted
time: 0ms
memory: 9932kb
input:
6 2 1 3 1 3 2
output:
0
result:
ok count=0
Test #3:
score: 0
Accepted
time: 2ms
memory: 14300kb
input:
3000 1 1 1 1 1 3 1 1 3 3 1 3 1 1 2 3 1 1 2 1 2 1 3 3 3 1 1 2 1 2 2 3 1 1 1 1 1 1 1 2 1 1 1 1 1 1 2 3 3 1 1 2 1 1 2 1 1 1 1 1 2 1 1 1 1 1 1 2 1 1 1 2 3 1 1 1 1 3 3 2 1 3 1 1 2 3 1 2 3 1 1 1 2 1 1 1 1 2 3 2 1 1 1 1 1 2 1 1 1 1 1 1 1 2 1 1 1 3 1 3 3 1 1 1 1 3 1 1 2 1 1 1 3 3 1 1 1 1 2 1 1 1 1 1 2 3 3 1...
output:
499 0 14 2416 4 29 2420 5 30 2422 7 46 2425 6 51 2426 8 39 2424 9 54 2428 11 67 2430 15 84 2434 19 97 2437 22 105 2440 21 113 2441 23 99 2438 24 128 2443 31 162 2447 35 181 2451 36 188 2452 37 197 2453 47 244 2461 45 249 2462 48 238 2460 59 283 2472 63 296 2475 64 299 2476 66 312 2478 69 318 2480 72...
result:
ok count=499
Test #4:
score: 0
Accepted
time: 0ms
memory: 14108kb
input:
3000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
1 0 1374 2901
result:
ok count=1
Test #5:
score: 0
Accepted
time: 2ms
memory: 10128kb
input:
3000 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2...
output:
1 1755 1756 1874
result:
ok count=1
Test #6:
score: 0
Accepted
time: 0ms
memory: 12008kb
input:
1500 1 1 1 2 1 1 1 2 2 2 2 2 1 1 3 1 2 2 3 1 2 2 2 2 1 2 1 2 1 1 3 1 2 2 2 2 1 1 3 1 1 2 2 3 2 1 3 1 1 2 2 2 1 2 2 2 2 2 1 2 3 2 3 2 3 2 1 3 2 1 2 3 2 2 3 2 3 1 1 3 1 3 1 3 3 3 1 3 3 3 1 1 3 1 3 1 3 1 1 1 3 1 3 1 3 3 1 1 1 3 1 1 3 1 1 1 1 1 3 3 3 3 1 3 1 1 1 1 3 3 3 3 3 3 1 3 1 1 1 3 1 3 1 1 1 1 3 1...
output:
500 1 7 542 4 9 544 5 10 545 12 16 547 14 20 549 15 21 550 18 22 551 26 27 554 29 34 557 30 33 556 31 35 558 36 41 559 38 44 561 40 50 563 39 51 564 43 49 562 45 54 566 46 53 565 58 59 570 60 61 571 62 63 572 52 57 573 64 65 569 66 70 576 67 68 575 69 72 577 71 73 578 74 75 579 48 56 580 76 364 568 ...
result:
ok count=500
Test #7:
score: 0
Accepted
time: 0ms
memory: 12200kb
input:
3000 3 1 1 1 1 3 3 2 1 1 1 2 3 1 3 3 3 3 1 1 3 1 3 3 1 1 1 1 1 3 3 1 1 1 1 3 1 3 1 1 3 3 3 3 1 3 1 3 1 3 1 3 1 1 1 3 3 1 3 1 1 1 3 1 3 3 3 3 1 1 1 1 3 1 1 1 3 3 1 2 3 3 1 3 3 3 3 3 3 3 1 1 1 1 3 1 3 1 3 3 3 3 1 3 1 1 3 3 1 1 1 3 3 1 3 3 1 3 1 3 1 3 2 3 1 3 1 1 3 1 1 1 3 3 1 1 3 3 2 2 2 2 2 2 2 2 2 2...
output:
1000 0 7 1887 1 11 1888 3 122 1890 4 139 1892 5 138 1891 2 140 1893 6 79 1889 8 141 1894 9 142 1895 10 144 1897 12 143 1896 13 146 1900 14 145 1899 17 150 1904 18 149 1903 16 151 1905 19 148 1902 21 153 1907 22 154 1908 23 155 1909 20 156 1910 24 152 1906 25 157 1911 15 158 1912 26 147 1901 27 159 1...
result:
ok count=1000
Test #8:
score: 0
Accepted
time: 2ms
memory: 12112kb
input:
3000 1 3 1 1 3 1 1 1 1 3 1 1 3 1 1 1 3 3 3 3 3 1 1 3 1 1 3 1 3 3 1 2 2 3 1 3 3 3 1 3 3 2 3 1 1 3 3 1 1 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 3 3 3 1 1 1 1 3 1 1 1 3 1 1 1 1 1 3 3 3 3 3 1 3 3 3 1 1 1 3 1 1 3 1 1 3 1 3 3 3 1 1 1 3 3 3 3 3 1 1 1...
output:
1000 0 31 1618 1 32 1619 2 41 1620 4 52 1622 7 55 1625 8 56 1626 9 57 1627 10 58 1628 11 59 1629 12 60 1630 13 61 1631 14 62 1632 15 63 1633 6 64 1634 16 54 1624 5 65 1635 17 53 1623 18 66 1636 3 67 1637 19 51 1621 20 68 1638 22 71 1641 23 70 1640 26 74 1644 28 76 1646 27 77 1647 29 75 1645 33 79 16...
result:
ok count=1000
Test #9:
score: 0
Accepted
time: 2ms
memory: 12064kb
input:
2997 3 1 2 2 1 1 1 1 1 1 3 1 3 3 1 3 3 3 1 3 1 2 1 1 3 1 2 2 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 3 3 1 1 3 1 3 1 1 3 3 1 3 1 3 3 3 1 1 1 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 3 1 3 1 1 1 1 1 3 3 3 1 3 1 1 3 3 3 1 3 3 1 1 1 3 1 1 3 1 1 3 2 3 3 3 2 3 2 3 1 2 1 1 3 1 1 3 2 2 2 2...
output:
999 0 2 1215 6 27 1219 8 31 1221 9 33 1223 10 32 1222 11 34 1224 7 35 1225 12 30 1220 13 36 1226 14 37 1227 15 38 1228 5 39 1229 16 26 1218 4 40 1230 17 21 1217 18 41 1231 19 42 1232 22 44 1234 23 45 1235 20 46 1236 24 43 1233 25 47 1237 51 74 1241 50 75 1242 52 73 1240 55 78 1245 56 79 1246 54 80 1...
result:
ok count=999
Test #10:
score: 0
Accepted
time: 0ms
memory: 12064kb
input:
2994 1 1 2 1 2 1 2 2 3 1 3 3 3 3 1 3 1 1 2 3 3 1 3 3 3 3 1 1 1 3 3 2 3 1 3 1 3 3 1 2 3 1 3 3 3 1 3 1 3 2 3 2 1 1 3 1 1 1 3 2 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 1 1 2 3 3 3 3 3 3 1 3 1 3 1 1 2 1 3 3 3 2 2 3 2 1 3 3 3 1 2 1 1 2 3 3 1 3 2 2 2 2 2 2 2 2...
output:
998 0 2 1925 3 6 1927 5 7 1928 1 4 1929 8 18 1926 9 31 1930 13 59 1934 12 61 1935 14 51 1933 16 63 1937 15 64 1938 17 62 1936 20 66 1940 21 67 1941 22 68 1942 23 69 1943 25 72 1946 26 71 1945 24 73 1947 27 70 1944 19 74 1948 28 65 1939 32 77 1951 33 78 1952 34 79 1953 35 80 1954 36 81 1955 38 83 195...
result:
ok count=998
Test #11:
score: 0
Accepted
time: 2ms
memory: 12060kb
input:
3000 1 1 1 3 2 3 2 3 1 1 1 1 2 3 1 2 1 2 1 3 3 2 2 3 3 2 3 2 2 3 3 3 3 3 1 3 2 1 2 3 2 3 3 3 2 1 3 3 3 2 1 1 1 1 2 1 3 1 3 2 2 2 1 2 3 3 3 2 1 3 1 3 2 3 1 3 2 3 3 1 2 1 2 2 3 1 3 2 2 1 1 2 3 1 1 3 1 3 2 2 3 2 2 1 3 2 2 2 3 3 2 3 1 2 2 1 1 1 2 3 2 1 3 2 1 1 1 3 3 1 3 1 3 2 2 1 1 1 1 2 1 2 3 1 2 1 2 2...
output:
1000 1 6 1501 2 15 1503 3 12 1502 0 4 1504 5 17 1498 7 21 1507 8 22 1508 9 25 1509 10 27 1510 13 36 1513 18 44 1517 19 49 1519 16 54 1520 20 40 1515 14 59 1523 23 38 1514 11 60 1525 24 28 1512 26 61 1526 29 63 1527 31 72 1530 33 82 1533 34 80 1532 37 87 1537 39 88 1538 43 101 1548 45 99 1546 46 102 ...
result:
ok count=1000
Test #12:
score: 0
Accepted
time: 2ms
memory: 14236kb
input:
3000 2 2 1 3 2 2 2 3 2 2 2 2 2 1 2 2 2 2 2 1 3 2 2 2 2 3 2 2 2 2 2 2 1 3 2 2 2 2 2 2 2 2 2 2 1 3 2 2 2 1 2 3 2 3 1 2 2 3 2 3 2 2 2 1 2 2 2 2 2 2 2 2 2 1 2 2 3 2 2 1 2 3 2 1 3 3 2 3 2 2 2 3 1 2 2 2 2 1 2 3 3 1 2 1 1 2 2 2 1 2 2 2 2 2 2 1 2 3 1 2 1 2 2 3 2 2 2 2 2 2 2 2 2 3 1 2 2 2 2 3 2 3 3 1 2 2 1 2...
output:
673 3 5 1538 2 4 1539 7 8 1537 19 22 1542 20 21 1541 25 26 1543 32 35 1545 33 34 1544 44 46 1546 45 47 1547 51 52 1549 49 50 1550 53 55 1548 54 56 1551 57 58 1552 59 60 1553 63 64 1554 76 77 1556 79 80 1558 81 82 1557 83 86 1559 84 88 1560 85 89 1561 87 90 1562 91 93 1563 92 94 1564 97 98 1565 99 10...
result:
ok count=673
Test #13:
score: 0
Accepted
time: 3ms
memory: 14252kb
input:
2999 2 2 3 3 2 1 2 1 1 2 2 3 2 3 2 3 2 2 2 1 2 3 2 2 2 2 1 3 2 3 3 2 1 2 3 2 2 2 2 1 2 2 2 2 2 3 2 2 3 1 2 2 2 3 2 2 2 3 3 2 2 2 3 3 3 2 1 1 2 2 2 1 2 2 1 1 2 2 2 2 2 1 2 2 2 3 2 2 3 3 3 1 1 2 2 3 2 2 2 1 2 2 2 2 2 2 2 2 1 2 2 2 1 2 3 3 1 1 2 2 2 2 1 1 2 2 3 2 3 2 3 2 2 2 3 2 2 2 1 2 1 3 2 3 2 2 2 1...
output:
683 5 9 1487 3 6 1488 7 10 1486 2 4 1489 8 12 1485 15 17 1493 19 20 1492 21 22 1494 26 28 1495 27 31 1496 30 35 1498 29 36 1499 32 33 1497 39 40 1501 45 46 1502 48 51 1504 49 50 1503 53 54 1505 62 65 1508 64 70 1511 66 69 1510 63 72 1512 67 68 1509 71 73 1513 74 76 1514 75 77 1515 81 82 1516 91 97 1...
result:
ok count=683
Test #14:
score: 0
Accepted
time: 0ms
memory: 14112kb
input:
2998 2 1 2 1 3 2 2 2 2 2 2 2 1 2 2 2 2 3 3 2 1 2 1 2 2 3 2 2 2 2 2 2 2 2 1 2 2 2 2 2 2 1 3 1 3 2 2 1 2 2 2 3 2 2 2 2 1 2 2 1 2 2 2 2 2 2 2 2 3 2 1 2 3 2 2 3 3 2 2 2 2 1 2 1 2 2 2 2 3 2 3 3 3 1 2 2 2 2 2 3 2 2 2 1 2 2 2 2 2 2 2 3 2 2 3 3 2 1 1 2 2 3 3 2 1 2 2 2 2 2 2 2 2 3 2 1 2 1 2 2 3 1 2 3 2 2 2 2...
output:
629 4 6 1541 17 19 1543 18 21 1544 20 23 1545 22 24 1546 25 26 1547 34 35 1548 41 45 1549 42 46 1550 43 48 1551 12 13 1552 44 49 1542 51 52 1554 56 57 1555 68 69 1557 70 71 1558 72 73 1559 59 60 1560 75 77 1556 47 50 1561 76 78 1553 88 89 1564 90 94 1565 91 95 1566 83 84 1567 92 96 1563 93 97 1568 8...
result:
ok count=629
Test #15:
score: 0
Accepted
time: 2ms
memory: 14120kb
input:
2997 1 1 3 2 3 3 2 2 1 2 2 2 2 2 2 1 3 3 2 2 2 3 2 2 2 2 3 2 1 3 2 3 2 3 2 3 3 2 2 2 2 2 2 2 1 1 2 2 3 3 2 1 2 2 3 3 2 2 1 1 1 2 1 2 1 2 2 1 2 1 3 1 3 3 1 2 2 2 2 2 2 1 2 2 2 3 2 2 3 2 2 1 2 2 3 2 1 2 2 2 3 2 2 1 3 1 2 2 2 1 3 2 2 1 2 3 2 3 1 3 2 2 3 2 2 2 2 1 2 2 2 1 1 2 3 2 2 2 3 2 3 1 2 2 3 2 2 2...
output:
712 0 3 1524 1 6 1525 4 9 1527 5 10 1528 2 7 1529 8 11 1526 15 18 1530 26 27 1535 28 30 1534 29 32 1536 31 34 1537 36 39 1541 44 46 1540 35 38 1542 45 47 1539 49 52 1544 48 50 1545 51 53 1543 55 57 1548 58 61 1547 59 63 1549 60 65 1550 62 66 1551 64 68 1552 67 75 1553 54 56 1554 69 76 1546 70 78 155...
result:
ok count=712
Test #16:
score: 0
Accepted
time: 0ms
memory: 10020kb
input:
3000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
1000 0 1000 2000 1 1001 2001 2 1002 2002 3 1003 2003 4 1004 2004 5 1005 2005 6 1006 2006 7 1007 2007 8 1008 2008 9 1009 2009 10 1010 2010 11 1011 2011 12 1012 2012 13 1013 2013 14 1014 2014 15 1015 2015 16 1016 2016 17 1017 2017 18 1018 2018 19 1019 2019 20 1020 2020 21 1021 2021 22 1022 2022 23 102...
result:
ok count=1000
Test #17:
score: 0
Accepted
time: 2ms
memory: 10012kb
input:
3000 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2...
output:
1 0 2 2999
result:
ok count=1
Test #18:
score: 0
Accepted
time: 2ms
memory: 12060kb
input:
15 2 3 3 2 1 3 2 1 1 1 3 2 3 1 2
output:
3 1 3 8 2 6 9 4 11 12
result:
ok count=3
Test #19:
score: 0
Accepted
time: 0ms
memory: 11980kb
input:
18 3 3 3 1 1 3 2 2 1 2 1 2 3 2 2 1 3 1
output:
6 0 6 8 1 7 10 2 11 15 3 9 12 4 13 16 5 14 17
result:
ok count=6
Test #20:
score: 0
Accepted
time: 2ms
memory: 12052kb
input:
16 1 3 3 2 1 3 1 2 2 2 3 1 3 2 1 2
output:
5 0 7 10 1 3 6 2 8 11 4 9 12 5 13 14
result:
ok count=5
Test #21:
score: 0
Accepted
time: 0ms
memory: 12056kb
input:
15 1 3 1 2 3 2 3 3 2 1 2 2 1 1 3
output:
5 0 3 7 1 5 9 4 10 13 2 11 14 6 8 12
result:
ok count=5
Test #22:
score: 0
Accepted
time: 2ms
memory: 11988kb
input:
18 1 3 1 3 2 1 1 3 2 2 2 3 2 3 2 1 1 3
output:
6 0 4 7 2 9 13 3 10 15 1 12 16 5 8 11 6 14 17
result:
ok count=6
Test #23:
score: 0
Accepted
time: 2ms
memory: 12040kb
input:
18 1 3 3 2 1 1 1 2 3 2 1 1 2 3 2 3 2 3
output:
6 0 3 8 1 7 10 2 9 11 4 12 13 5 14 15 6 16 17
result:
ok count=6
Test #24:
score: 0
Accepted
time: 0ms
memory: 11992kb
input:
18 1 2 1 2 3 2 3 3 2 2 3 1 1 3 3 1 2 1
output:
6 2 3 13 4 5 12 0 1 14 6 8 11 7 9 15 10 16 17
result:
ok count=6
Test #25:
score: 0
Accepted
time: 0ms
memory: 12040kb
input:
15 1 2 1 2 3 3 1 1 1 2 3 2 3 2 3
output:
5 2 3 4 8 9 10 0 1 5 7 11 12 6 13 14
result:
ok count=5
Test #26:
score: 0
Accepted
time: 0ms
memory: 12180kb
input:
18 3 2 1 2 1 3 3 1 1 3 2 1 2 3 2 1 2 3
output:
6 0 1 8 2 3 9 4 12 13 5 10 11 6 14 15 7 16 17
result:
ok count=6
Test #27:
score: 0
Accepted
time: 0ms
memory: 12276kb
input:
15 1 2 3 2 3 3 3 1 3 2 1 2 1 2 1
output:
5 0 1 8 2 3 7 4 9 10 5 11 12 6 13 14
result:
ok count=5
Test #28:
score: 0
Accepted
time: 2ms
memory: 14088kb
input:
18 2 1 2 2 2 2 1 3 1 3 3 3 2 2 2 2 3 2
output:
2 6 12 16 1 2 7
result:
ok count=2
Test #29:
score: 0
Accepted
time: 2ms
memory: 14104kb
input:
17 1 2 2 2 2 1 1 1 1 3 2 2 1 2 1 2 2
output:
1 0 1 9
result:
ok count=1
Test #30:
score: 0
Accepted
time: 0ms
memory: 14320kb
input:
16 1 2 2 2 2 3 3 1 3 3 2 2 2 2 3 2
output:
2 0 1 6 7 10 14
result:
ok count=2
Test #31:
score: 0
Accepted
time: 1ms
memory: 9936kb
input:
18 1 1 1 1 1 2 2 2 2 2 2 2 3 3 3 3 3 3
output:
5 0 5 12 1 6 13 2 7 14 3 8 15 4 9 16
result:
ok count=5
Test #32:
score: 0
Accepted
time: 2ms
memory: 12136kb
input:
6 1 2 3 2 3 1
output:
2 0 1 4 2 3 5
result:
ok count=2
Test #33:
score: 0
Accepted
time: 0ms
memory: 10132kb
input:
6 2 1 3 3 1 2
output:
0
result:
ok count=0
Test #34:
score: 0
Accepted
time: 0ms
memory: 12044kb
input:
6 3 1 2 2 3 1
output:
2 0 3 5 1 2 4
result:
ok count=2
Test #35:
score: 0
Accepted
time: 0ms
memory: 14232kb
input:
15000 2 1 3 1 1 2 3 1 3 1 1 1 3 2 2 2 1 3 2 3 3 3 3 2 1 1 2 2 1 1 1 1 1 1 3 3 3 3 3 1 3 1 2 1 1 1 1 1 2 1 2 1 2 1 3 3 3 3 3 2 2 1 1 2 3 3 3 2 3 2 1 2 1 1 1 1 1 3 2 3 2 1 1 2 1 1 1 1 3 2 1 2 1 1 2 1 2 1 2 1 3 3 2 3 2 3 1 2 1 3 3 1 2 2 3 1 2 3 2 3 3 1 1 1 3 3 2 2 2 2 2 1 3 3 3 2 2 1 2 1 3 3 3 3 2 2 1 ...
output:
4997 1 5 7462 2 14 7466 3 13 7465 4 15 7467 6 23 7470 7 18 7468 8 26 7471 9 27 7472 10 42 7473 12 50 7476 16 59 7479 17 52 7477 19 60 7481 20 63 7482 11 67 7483 21 48 7475 22 71 7485 24 69 7484 25 78 7488 30 89 7494 33 98 7502 34 96 7498 32 102 7503 35 94 7497 36 104 7504 37 107 7505 38 112 7506 39 ...
result:
ok count=4997
Test #36:
score: 0
Accepted
time: 0ms
memory: 12120kb
input:
15000 3 1 3 3 2 1 1 3 1 2 2 3 1 2 1 2 1 2 1 1 2 2 1 2 3 2 3 2 3 3 1 1 2 1 2 2 3 3 3 2 3 2 1 1 3 2 2 3 1 2 1 3 1 3 1 3 2 1 1 1 3 3 2 2 3 3 1 2 3 2 3 2 2 2 1 2 3 2 2 1 1 3 3 2 1 3 3 3 2 2 1 1 3 1 3 2 2 3 3 1 2 2 2 3 1 1 2 1 1 1 1 1 2 2 1 2 1 3 3 3 3 3 2 3 1 1 1 1 1 1 2 1 1 2 3 2 1 3 3 3 2 1 1 3 2 1 1 ...
output:
4999 0 4 7469 1 9 7470 2 10 7471 3 15 7474 5 13 7472 6 20 7478 7 17 7475 8 21 7479 11 25 7481 12 23 7480 16 32 7483 22 39 7488 24 41 7489 19 45 7491 26 35 7487 18 46 7492 28 34 7484 14 27 7493 29 49 7482 30 56 7494 36 67 7497 37 69 7498 38 71 7500 40 72 7505 44 77 7508 47 78 7509 50 88 7511 48 89 75...
result:
ok count=4999
Test #37:
score: 0
Accepted
time: 3ms
memory: 14192kb
input:
15000 1 2 1 3 2 3 2 3 2 3 3 1 3 3 1 1 3 1 2 3 1 1 3 2 1 2 1 2 1 1 2 1 1 1 3 3 1 2 3 3 3 1 3 3 2 1 3 3 3 3 1 3 2 3 3 1 3 2 3 1 3 3 1 2 2 2 1 3 3 2 3 2 3 3 2 3 2 1 1 3 2 3 3 1 1 1 3 1 3 1 2 1 3 2 2 1 2 1 2 3 3 1 1 2 1 1 3 3 3 3 1 1 2 2 3 1 2 1 3 1 1 3 2 3 1 2 1 3 1 1 3 3 3 1 3 3 3 1 2 2 2 1 2 1 3 2 3 ...
output:
4998 2 6 7470 3 4 7469 0 1 7471 5 8 7466 7 18 7472 11 27 7477 14 44 7484 13 52 7485 15 37 7481 16 63 7489 17 57 7487 19 65 7492 20 64 7491 21 69 7493 22 71 7494 12 74 7495 24 30 7479 10 25 7496 26 76 7475 9 23 7497 28 80 7474 32 94 7500 33 96 7502 34 98 7503 35 103 7504 36 112 7505 31 113 7506 38 93...
result:
ok count=4998
Test #38:
score: 0
Accepted
time: 0ms
memory: 14172kb
input:
15000 1 2 1 1 1 2 3 1 2 3 3 3 2 2 1 2 1 3 3 2 3 2 1 1 2 3 3 1 1 2 1 3 2 3 1 1 2 2 2 1 3 1 2 3 3 2 2 1 2 3 3 2 2 2 2 3 3 3 2 3 3 2 1 2 3 3 1 3 3 1 1 3 3 3 2 3 2 1 3 1 1 2 1 3 1 2 1 1 2 1 2 3 2 2 3 3 2 2 1 3 3 2 3 1 2 2 3 3 2 3 1 3 1 1 3 1 3 3 1 3 1 2 2 2 1 3 1 3 2 2 2 2 3 2 1 2 2 3 3 1 2 3 1 1 3 1 2 ...
output:
5000 0 1 7454 4 13 7461 6 12 7460 7 15 7465 9 19 7467 3 8 7468 10 21 7458 2 5 7469 11 24 7455 14 29 7470 16 32 7475 20 42 7484 22 38 7482 18 45 7485 23 37 7481 27 51 7490 28 52 7491 30 53 7492 31 54 7493 34 61 7498 33 63 7499 35 58 7497 39 74 7501 41 81 7503 44 88 7505 43 90 7506 47 85 7504 55 96 75...
result:
ok count=5000
Test #39:
score: 0
Accepted
time: 3ms
memory: 12128kb
input:
15000 3 3 1 1 1 1 3 3 3 3 3 1 3 1 3 1 1 3 1 3 3 3 3 1 2 3 3 3 3 3 3 3 3 3 3 1 3 1 1 3 3 2 2 2 2 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 2 3 1 1 3 2 1 1 1 1 3 3 1 3 3 1 3 1 3 1 1 3 1 3 3 1 1 1 1 1 3 1 1 3 3 1 1 3 3 3 3 3 1 3 1 1 1 1 3 3 3 3 3 1 3 3 3 2 1 3 2 3 1 1 ...
output:
5000 1 42 5306 2 41 5305 3 43 5307 0 44 5308 4 24 5304 6 47 5310 7 48 5311 5 49 5312 8 46 5309 10 51 5314 11 52 5315 12 53 5316 13 54 5317 14 56 5319 15 55 5318 9 57 5320 16 50 5313 18 59 5322 19 60 5323 20 61 5324 22 63 5326 21 64 5327 23 62 5325 29 69 5332 30 70 5333 31 71 5334 32 72 5335 33 73 53...
result:
ok count=5000
Test #40:
score: 0
Accepted
time: 0ms
memory: 12120kb
input:
15000 3 1 3 1 3 3 1 1 1 1 3 3 3 3 3 3 1 1 3 1 1 3 3 3 3 3 3 3 3 3 2 3 1 3 3 3 3 3 3 1 3 1 2 2 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 3 1 1 1 3 1 1 3 1 1 3 2 2 2 2 3 2 2 2 2 2 2 2 2 2 1 1 1 3 1 1 1 3 3 3 3 1 1 1 1 3 1 3 1 1 3 1 2 1 2 1 3 1 3 1 1 1 1 3 3 3 3 ...
output:
5000 0 30 6171 2 43 6173 3 45 6174 1 46 6175 4 42 6172 6 48 6177 5 49 6178 7 47 6176 8 50 6179 9 51 6180 12 54 6183 13 55 6184 14 56 6185 15 57 6186 16 58 6187 17 59 6188 18 61 6190 19 60 6189 11 62 6191 20 53 6182 21 63 6192 23 65 6194 24 66 6195 27 69 6198 29 71 6200 31 73 6202 32 72 6201 36 77 62...
result:
ok count=5000
Test #41:
score: 0
Accepted
time: 0ms
memory: 12348kb
input:
15000 3 3 1 1 1 1 3 3 3 1 3 1 3 1 3 1 3 3 3 3 1 3 3 1 1 1 3 1 1 1 1 3 1 1 3 3 1 1 1 3 1 3 1 3 3 1 1 1 3 1 3 3 3 3 3 3 3 1 3 3 3 1 3 1 3 3 3 3 3 3 3 3 3 1 1 1 1 3 3 1 3 3 3 1 3 3 1 3 3 1 3 3 3 3 1 1 1 1 3 3 1 3 1 3 3 1 3 1 1 3 1 3 1 3 3 3 1 1 1 1 3 3 3 3 1 3 1 3 1 1 3 1 1 1 3 1 1 1 3 2 3 3 3 3 1 1 1 ...
output:
5000 0 139 6958 1 472 6960 2 444 6959 4 475 6962 5 476 6963 6 477 6964 3 478 6965 7 474 6961 8 479 6966 9 480 6967 10 481 6968 11 483 6970 12 482 6969 14 485 6972 15 486 6973 13 487 6974 16 484 6971 17 488 6975 18 489 6976 19 491 6978 20 490 6977 23 494 6981 24 495 6982 22 496 6983 25 493 6980 27 49...
result:
ok count=5000
Test #42:
score: 0
Accepted
time: 0ms
memory: 12248kb
input:
6000 1 3 1 1 3 3 3 1 1 1 1 1 3 1 1 1 3 1 3 3 3 1 3 1 1 1 3 3 3 3 1 1 3 1 3 1 3 3 3 3 3 3 3 3 3 3 1 3 1 3 1 1 1 1 3 3 3 1 1 1 1 3 1 3 1 3 1 3 1 1 1 1 3 3 1 3 3 3 1 3 3 3 1 3 3 3 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2...
output:
2000 0 89 2549 1 91 2551 2 90 2550 3 92 2552 4 93 2553 6 95 2555 5 96 2556 7 94 2554 8 97 2557 10 99 2559 11 100 2560 12 101 2561 13 102 2562 14 103 2563 15 104 2564 9 105 2566 16 98 2558 17 106 2567 20 109 2570 21 110 2571 23 112 2573 22 113 2574 24 111 2572 19 114 2575 25 108 2569 26 115 2576 27 1...
result:
ok count=2000
Test #43:
score: 0
Accepted
time: 0ms
memory: 12108kb
input:
9000 1 1 1 1 1 1 1 1 1 3 1 1 1 2 2 1 2 2 2 2 2 2 2 2 2 2 2 2 3 1 1 3 2 1 3 3 1 3 3 2 3 2 3 2 2 2 2 2 2 2 2 2 3 3 3 3 1 3 3 1 3 1 3 1 1 3 2 3 3 1 3 1 1 1 1 3 3 1 1 1 3 3 1 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 3 1 1 3 3 3 1 1 1 3 1 3 3 1 1 3 3 3 1 3 1 1 3 3 1 1 1 1 3 1 3 1 1...
output:
3000 0 13 4207 2 16 4209 4 18 4211 5 19 4212 6 20 4213 8 22 4215 7 23 4216 9 21 4214 10 24 4217 11 25 4218 12 26 4219 15 27 4220 3 17 4221 28 32 4210 29 39 4222 30 43 4224 31 41 4223 33 44 4225 34 45 4226 1 14 4227 35 46 4208 37 48 4229 36 49 4230 38 47 4228 40 50 4231 52 66 4233 55 86 4236 54 87 42...
result:
ok count=3000
Test #44:
score: 0
Accepted
time: 3ms
memory: 12204kb
input:
12000 3 3 3 3 3 1 3 1 3 1 1 3 1 1 3 1 3 3 3 1 1 1 3 1 1 1 1 3 3 3 2 1 1 1 3 3 3 3 1 3 1 3 1 1 1 1 1 3 3 1 1 3 3 1 1 1 2 1 3 3 1 1 1 1 1 1 1 3 1 3 3 1 3 1 3 3 1 1 1 3 3 3 1 1 1 3 3 1 3 3 1 3 3 3 1 1 3 1 1 1 3 1 1 3 3 1 1 1 1 1 3 3 1 3 1 3 3 1 1 3 1 3 1 3 3 3 3 3 3 1 1 1 1 1 3 1 1 1 3 1 3 1 3 3 3 3 1 ...
output:
4000 1 56 6544 2 233 6545 3 270 6546 4 334 6548 5 309 6547 6 335 6549 7 339 6550 8 342 6551 0 343 6552 9 30 6543 10 345 6554 11 344 6553 14 348 6557 15 349 6558 16 350 6559 13 351 6560 17 347 6556 12 352 6561 18 346 6555 19 353 6562 22 356 6565 23 357 6566 25 359 6568 26 360 6569 24 361 6570 27 358 ...
result:
ok count=4000
Test #45:
score: 0
Accepted
time: 3ms
memory: 12120kb
input:
15000 3 3 1 3 3 2 3 2 1 1 2 1 3 1 1 3 1 2 2 2 2 1 2 2 2 2 2 2 2 2 1 1 2 3 2 2 1 1 1 1 1 1 1 3 3 3 1 1 3 1 3 1 1 3 3 3 1 3 1 3 1 1 1 3 3 1 3 1 3 1 2 1 3 1 3 1 1 1 1 3 3 3 3 3 3 1 3 1 3 3 1 3 3 1 1 1 1 1 1 3 1 1 1 1 3 3 3 3 2 3 3 3 1 3 1 3 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 ...
output:
5000 1 7 5433 0 10 5434 2 5 5432 3 17 5435 4 18 5436 6 19 5437 8 20 5438 11 23 5440 12 24 5441 13 25 5442 14 26 5443 15 27 5444 16 28 5445 30 32 5447 33 35 5449 36 70 5450 37 108 5451 39 119 5453 40 120 5454 41 121 5455 42 123 5457 43 122 5456 38 124 5458 44 118 5452 31 34 5459 45 125 5448 48 128 54...
result:
ok count=5000
Test #46:
score: 0
Accepted
time: 3ms
memory: 12112kb
input:
15000 3 3 3 3 1 1 1 3 1 1 1 3 1 1 1 3 1 3 3 3 3 3 1 1 3 1 1 3 3 3 1 1 1 3 1 1 3 1 1 1 1 1 1 1 1 3 3 3 1 3 3 2 3 1 1 3 3 3 3 3 1 1 1 3 3 2 3 1 1 3 3 3 3 1 3 3 3 1 1 1 1 3 3 3 1 3 3 1 1 2 3 1 1 1 3 3 1 1 3 3 3 3 1 3 3 1 1 3 1 3 3 1 1 1 3 3 1 1 1 3 1 2 1 1 2 1 1 1 2 3 3 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 ...
output:
5000 0 51 6950 1 65 6951 3 121 6953 4 124 6954 5 128 6955 6 132 6956 7 133 6957 2 134 6958 8 89 6952 10 136 6960 9 137 6961 11 135 6959 13 139 6963 14 140 6964 12 141 6965 15 138 6962 16 143 6967 17 142 6966 19 145 6969 20 146 6970 21 147 6971 18 148 6972 22 144 6968 24 150 6974 25 151 6975 26 152 6...
result:
ok count=5000
Test #47:
score: 0
Accepted
time: 0ms
memory: 12128kb
input:
15000 3 3 1 3 3 1 1 2 1 1 3 1 1 3 1 3 1 1 1 3 3 1 3 3 1 3 1 1 1 1 3 3 3 2 2 1 2 3 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 1 1 1 3 1 3 3 3 3 1 1 3 3 3 1 3 3 1 1 1 1 1 1 3 1 1 1 3 3 1 1 3 1 3 1 1 3 1 1 1 1 3 3 3 3 3 1 3 3 3 1 1 3 3 1 1 3 1 3 3 3 3 3 3 3 1 3 1 3 1 1 1 3 3 3 1 ...
output:
5000 0 7 6155 2 34 6157 3 36 6158 4 39 6159 5 40 6160 1 41 6161 6 33 6156 9 43 6163 10 44 6164 11 45 6165 13 47 6167 15 49 6169 17 51 6171 18 53 6173 19 52 6172 16 54 6174 20 50 6170 22 56 6176 21 57 6177 23 55 6175 24 58 6178 25 59 6179 26 60 6180 30 64 6184 29 65 6185 31 63 6183 28 66 6186 32 62 6...
result:
ok count=5000
Test #48:
score: 0
Accepted
time: 0ms
memory: 14284kb
input:
15000 1 2 2 1 2 2 3 2 2 2 2 1 2 1 3 2 2 2 2 3 2 2 2 2 1 2 2 1 2 2 2 2 3 2 2 2 2 3 2 2 2 2 1 1 2 2 2 1 1 3 2 2 2 2 3 2 2 1 2 2 2 1 3 2 1 2 2 2 2 2 2 3 2 2 3 2 2 3 2 1 2 2 2 2 2 3 2 2 2 2 2 3 3 1 2 1 2 2 2 2 3 2 1 1 2 2 2 2 2 1 2 2 2 2 2 3 2 2 1 2 3 3 2 2 2 1 2 2 2 2 3 2 2 2 2 2 3 3 3 2 1 2 1 2 1 2 3 ...
output:
3267 3 4 7511 6 7 7512 11 12 7513 13 15 7514 0 1 7515 14 16 7510 19 20 7516 24 25 7517 32 33 7519 27 28 7520 37 38 7518 43 45 7522 47 50 7523 48 51 7524 49 52 7525 54 55 7526 57 58 7527 61 63 7528 62 65 7529 64 66 7531 71 72 7530 42 44 7532 74 75 7521 77 78 7533 79 80 7534 91 94 7536 92 97 7538 93 9...
result:
ok count=3267
Test #49:
score: 0
Accepted
time: 1ms
memory: 14092kb
input:
15000 1 2 2 2 1 2 2 2 2 2 1 2 2 2 1 3 2 1 1 2 2 1 2 2 2 2 2 2 2 2 2 1 3 2 1 1 2 3 3 1 2 1 1 1 3 2 2 1 2 2 2 2 2 2 2 2 3 2 1 2 2 3 1 2 2 1 1 3 2 2 3 2 2 3 3 2 3 2 2 1 2 2 3 2 2 2 2 2 3 1 2 2 1 2 2 2 1 2 2 2 2 2 2 2 2 2 3 2 3 2 2 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 2 2 3 2 1 2 2 2 2 3 2 1 2 2 1 2 2 ...
output:
3340 0 1 7502 14 16 7505 15 19 7506 17 20 7507 21 23 7509 32 36 7511 34 40 7512 35 45 7513 31 33 7514 37 46 7510 18 22 7515 38 48 7508 39 49 7516 43 53 7520 44 52 7519 47 54 7522 56 57 7521 58 59 7524 61 63 7523 65 68 7526 66 71 7528 67 69 7527 62 64 7529 70 72 7525 73 75 7530 42 51 7531 74 77 7518 ...
result:
ok count=3340
Test #50:
score: 0
Accepted
time: 3ms
memory: 14384kb
input:
14000 1 2 1 2 1 2 2 3 2 2 1 2 2 2 2 2 2 2 2 2 2 2 2 2 1 3 2 2 2 2 2 3 2 2 2 3 1 3 1 1 2 2 2 2 1 3 2 2 1 2 2 2 1 2 3 2 2 1 2 2 2 2 2 1 2 2 2 2 2 1 2 2 2 2 2 3 2 2 3 1 2 2 2 2 1 2 2 2 1 2 2 2 2 2 2 2 2 3 3 1 1 2 2 2 1 2 2 3 1 2 2 2 2 2 2 2 3 2 2 2 1 2 1 3 2 3 2 2 3 2 2 2 1 1 3 2 2 2 1 2 2 2 2 2 1 2 1 ...
output:
3042 2 3 6998 4 5 6999 7 8 7000 10 11 7001 24 26 7002 25 27 7003 0 1 7004 31 32 6997 35 40 7005 36 41 7006 37 42 7007 44 47 7010 39 49 7011 45 46 7009 48 50 7012 54 55 7014 57 58 7015 63 64 7016 75 76 7018 78 80 7019 88 89 7022 84 85 7023 97 101 7021 98 102 7024 99 103 7025 100 105 7026 107 109 7028...
result:
ok count=3042
Test #51:
score: 0
Accepted
time: 3ms
memory: 14204kb
input:
13000 2 2 3 3 2 2 2 1 2 3 2 1 2 1 2 3 1 3 3 1 2 1 2 1 2 3 2 2 2 2 2 2 1 2 2 1 3 3 3 1 2 2 3 2 3 2 1 2 2 2 2 1 2 1 2 2 2 2 1 2 2 2 2 3 3 2 2 2 2 1 2 3 2 2 3 2 2 1 2 1 2 2 2 1 2 2 1 1 2 3 1 2 2 1 2 1 2 2 2 2 1 3 2 2 2 2 2 2 2 1 1 2 3 2 2 2 2 2 2 2 1 2 1 2 2 3 1 2 2 3 1 2 2 2 1 2 3 3 2 2 1 1 1 2 3 1 2 ...
output:
2941 2 4 6549 3 5 6551 7 8 6550 9 10 6552 15 20 6555 16 22 6556 13 14 6557 17 24 6554 11 12 6558 18 26 6553 21 28 6560 25 30 6562 32 33 6563 35 40 6564 23 29 6565 36 41 6561 37 43 6566 19 27 6567 38 45 6559 42 48 6569 39 49 6570 44 47 6568 46 50 6571 58 59 6574 63 65 6575 53 54 6576 64 66 6573 69 70...
result:
ok count=2941
Test #52:
score: 0
Accepted
time: 0ms
memory: 16264kb
input:
11000 2 2 2 3 2 2 2 2 2 2 2 1 2 1 2 2 2 2 1 2 2 2 2 2 2 2 2 2 2 1 2 2 2 2 2 2 2 3 2 2 2 2 1 2 1 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 1 3 2 1 1 2 2 2 2 1 2 2 3 2 2 1 2 2 2 2 2 1 2 2 2 2 2 2 2 1 1 2 2 2 2 2 2 2 2 2 3 2 2 3 2 1 3 2 2 2 2 1 2 2 3 2 2 3 2 2 2 2 2 2 2 3 2 1 2 2 3 1 2 2 3 2 2 3 2 3 2 2 2 ...
output:
2460 3 4 5583 11 12 5584 18 19 5586 37 38 5588 44 47 5591 45 46 5590 63 66 5592 64 69 5593 65 70 5594 67 71 5595 76 77 5598 79 80 5599 94 96 5602 104 105 5603 93 95 5604 107 108 5601 109 112 5606 110 111 5605 118 119 5608 121 122 5609 115 116 5610 129 130 5607 131 132 5612 134 136 5611 138 139 5614 ...
result:
ok count=2460
Test #53:
score: 0
Accepted
time: 3ms
memory: 14388kb
input:
11000 2 2 3 1 2 1 2 2 2 3 2 2 2 2 2 3 2 1 2 2 1 2 3 2 1 2 3 2 2 1 2 2 2 2 2 2 3 3 2 2 2 2 2 1 2 1 2 2 1 1 2 1 1 2 2 3 2 2 2 2 2 2 2 1 2 2 3 1 1 2 2 1 3 2 1 2 3 2 3 1 2 2 2 1 2 2 2 2 3 2 2 2 3 1 2 1 2 2 2 2 3 2 1 2 2 1 3 2 3 3 2 2 2 1 2 2 2 2 2 3 1 2 2 1 2 2 3 2 2 3 2 2 2 2 1 3 2 2 2 2 2 1 2 2 3 2 2 ...
output:
2423 3 6 5412 5 7 5413 9 10 5414 17 18 5416 15 16 5417 20 21 5415 22 23 5418 2 4 5419 24 25 5411 26 27 5420 29 30 5422 36 38 5421 37 39 5424 43 44 5423 48 50 5426 49 53 5427 52 57 5430 55 56 5429 63 64 5431 66 69 5432 71 75 5435 68 77 5436 72 73 5434 74 80 5437 67 70 5438 76 81 5433 78 82 5439 88 89...
result:
ok count=2423
Test #54:
score: 0
Accepted
time: 3ms
memory: 14152kb
input:
11000 2 1 1 3 2 2 2 2 2 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 2 2 2 2 2 2 3 2 2 2 3 2 1 2 1 2 1 2 2 2 2 3 2 2 2 2 2 2 3 2 1 2 3 1 3 2 2 3 2 2 3 2 1 3 1 3 2 2 2 2 2 2 1 3 2 2 2 2 1 2 2 2 2 3 2 2 3 3 1 2 2 2 2 2 2 2 2 2 2 3 2 2 3 2 2 2 2 3 2 2 1 1 2 3 3 2 3 1 1 3 1 2 2 2 3 2 1 2 2 2 3 3 3 2 1 2 2 2 3 2 2 ...
output:
2372 2 6 5491 3 5 5490 9 10 5492 25 26 5494 32 33 5493 36 37 5495 40 41 5497 42 43 5499 47 48 5498 54 55 5500 56 57 5501 38 39 5502 58 61 5496 59 64 5504 60 62 5503 1 4 5505 63 65 5489 66 67 5506 68 72 5507 69 73 5508 70 75 5510 71 74 5509 78 80 5511 84 85 5513 93 96 5516 92 97 5517 94 95 5515 105 1...
result:
ok count=2372
Test #55:
score: 0
Accepted
time: 3ms
memory: 16432kb
input:
11000 2 2 1 2 3 2 2 1 2 2 2 3 1 2 2 2 2 2 2 2 3 2 2 1 2 2 2 2 2 3 2 2 1 1 2 3 2 3 2 2 2 2 2 2 2 2 1 3 2 3 3 2 2 2 3 2 2 2 1 2 2 1 3 3 2 2 2 3 2 2 2 2 3 2 1 1 2 2 2 2 2 2 2 2 2 2 2 1 2 3 2 2 2 2 2 1 2 2 2 2 2 2 2 1 3 1 1 2 3 3 2 2 2 2 2 1 2 2 2 2 1 2 2 1 2 3 2 2 2 2 2 1 1 3 2 2 1 2 3 2 2 2 1 1 2 2 2 ...
output:
2490 4 5 5550 7 8 5551 11 13 5552 12 14 5554 20 21 5553 23 24 5555 2 3 5556 29 30 5549 33 36 5558 35 38 5559 32 34 5560 37 39 5557 46 51 5562 47 48 5561 49 52 5563 50 53 5564 54 55 5565 58 59 5566 61 65 5568 62 64 5567 67 68 5570 72 73 5571 63 66 5572 74 76 5569 87 88 5574 89 90 5575 103 107 5577 10...
result:
ok count=2490
Test #56:
score: 0
Accepted
time: 3ms
memory: 14164kb
input:
15000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...
output:
1 7734 8258 14999
result:
ok count=1
Test #57:
score: 0
Accepted
time: 0ms
memory: 12052kb
input:
15000 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 ...
output:
1 1354 1355 5343
result:
ok count=1
Test #58:
score: 0
Accepted
time: 3ms
memory: 10024kb
input:
15000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...
output:
5000 0 5000 10000 1 5001 10001 2 5002 10002 3 5003 10003 4 5004 10004 5 5005 10005 6 5006 10006 7 5007 10007 8 5008 10008 9 5009 10009 10 5010 10010 11 5011 10011 12 5012 10012 13 5013 10013 14 5014 10014 15 5015 10015 16 5016 10016 17 5017 10017 18 5018 10018 19 5019 10019 20 5020 10020 21 5021 100...
result:
ok count=5000
Test #59:
score: 0
Accepted
time: 0ms
memory: 10052kb
input:
15000 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 ...
output:
1 0 1 14998
result:
ok count=1
Test #60:
score: 0
Accepted
time: 0ms
memory: 10192kb
input:
15000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...
output:
3000 0 6000 9000 1 6001 9001 2 6002 9002 3 6003 9003 4 6004 9004 5 6005 9005 6 6006 9006 7 6007 9007 8 6008 9008 9 6009 9009 10 6010 9010 11 6011 9011 12 6012 9012 13 6013 9013 14 6014 9014 15 6015 9015 16 6016 9016 17 6017 9017 18 6018 9018 19 6019 9019 20 6020 9020 21 6021 9021 22 6022 9022 23 602...
result:
ok count=3000
Test #61:
score: 0
Accepted
time: 0ms
memory: 10068kb
input:
14997 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...
output:
4977 0 4977 9976 1 4978 9977 2 4979 9978 3 4980 9979 4 4981 9980 5 4982 9981 6 4983 9982 7 4984 9983 8 4985 9984 9 4986 9985 10 4987 9986 11 4988 9987 12 4989 9988 13 4990 9989 14 4991 9990 15 4992 9991 16 4993 9992 17 4994 9993 18 4995 9994 19 4996 9995 20 4997 9996 21 4998 9997 22 4999 9998 23 500...
result:
ok count=4977
Test #62:
score: 0
Accepted
time: 0ms
memory: 12176kb
input:
91 2 1 2 2 1 3 1 2 1 2 2 1 2 3 3 1 2 2 2 1 3 1 3 1 1 3 1 2 1 2 1 3 1 1 3 2 3 1 2 3 2 2 2 2 1 2 1 1 3 2 2 2 1 1 2 3 3 2 3 3 3 3 1 1 3 2 3 3 1 3 3 3 3 3 2 1 2 2 2 3 2 3 2 1 3 1 3 1 3 1 1
output:
29 4 9 55 5 7 53 6 10 56 8 12 58 11 16 59 1 2 60 13 17 52 14 27 62 15 18 61 19 35 64 20 29 63 21 38 66 22 41 68 23 40 67 24 42 69 26 45 71 28 49 72 30 50 73 31 51 75 32 54 79 33 57 81 34 65 83 36 76 85 37 74 84 39 78 87 44 77 86 46 80 88 25 43 47 70 82 89
result:
ok count=29
Test #63:
score: 0
Accepted
time: 0ms
memory: 12040kb
input:
92 3 1 3 3 3 3 3 1 3 2 1 3 3 3 1 1 1 2 2 1 2 1 2 2 2 3 2 1 3 3 2 3 3 2 3 3 2 3 3 2 2 1 2 2 3 3 2 2 2 3 2 1 3 2 1 2 1 1 1 1 1 3 1 3 1 2 1 1 2 2 2 2 3 1 1 3 2 1 1 1 1 1 1 3 1 2 2 3 3 2 2 2
output:
29 1 17 49 2 18 51 4 22 54 5 23 56 6 24 57 3 26 58 7 20 52 8 30 59 0 9 60 10 33 45 12 39 62 13 42 64 14 40 63 11 43 66 15 36 61 19 47 72 25 50 74 27 53 75 28 55 77 29 65 78 31 68 79 32 69 80 34 70 81 35 71 82 21 76 83 37 48 73 16 85 87 38 46 67 41 86 88
result:
ok count=29
Test #64:
score: 0
Accepted
time: 2ms
memory: 14088kb
input:
93 1 1 3 1 1 3 1 1 2 3 1 1 1 2 3 3 2 1 1 3 1 3 3 2 3 3 1 3 2 2 3 3 1 3 1 1 1 2 2 3 1 2 3 1 3 3 2 3 2 3 2 3 2 3 2 3 3 2 1 3 2 2 1 1 1 2 1 1 2 2 2 1 1 2 3 1 2 2 3 3 2 1 2 2 1 2 2 2 2 3 3 2 2
output:
28 1 13 39 2 16 40 3 23 42 4 29 44 5 28 43 6 37 45 7 38 47 0 8 9 36 41 49 10 46 51 11 48 53 12 50 55 15 54 58 17 57 59 14 60 62 18 52 56 19 61 63 21 68 71 22 69 72 20 70 74 24 65 66 25 73 75 26 76 78 30 80 81 31 82 84 32 83 89 34 77 79 35 85 90
result:
ok count=28
Test #65:
score: 0
Accepted
time: 0ms
memory: 12272kb
input:
94 3 3 1 1 3 2 1 3 2 1 2 1 1 2 2 2 2 3 2 2 1 1 3 1 2 1 2 3 3 3 2 2 1 3 2 1 2 2 1 2 3 1 2 1 2 1 3 1 3 1 3 3 2 2 2 1 1 3 2 2 3 3 3 2 2 3 3 3 2 3 2 1 2 2 1 1 2 1 1 1 3 2 2 1 3 3 1 3 1 3 3 3 2 1
output:
30 0 5 49 2 10 51 1 13 55 3 8 50 4 14 56 6 15 57 9 18 61 11 19 62 12 24 65 20 30 67 21 31 69 22 34 71 17 36 74 23 26 66 7 16 75 25 37 60 27 39 77 28 42 78 29 44 79 32 52 80 33 53 83 35 54 84 38 58 85 40 59 86 41 63 87 45 68 89 43 70 90 46 64 88 47 72 91 48 73 93
result:
ok count=30
Test #66:
score: 0
Accepted
time: 0ms
memory: 14316kb
input:
94 3 2 3 2 1 2 1 3 3 2 1 3 2 3 1 3 2 1 2 2 2 3 3 1 3 3 1 2 1 1 1 2 3 2 1 2 2 2 2 2 3 1 3 3 2 3 3 3 1 1 1 2 1 1 1 3 3 3 1 1 3 1 3 1 2 3 3 2 1 1 2 3 2 1 2 2 3 1 3 3 1 1 1 3 2 3 1 2 2 2 2 3 1 1
output:
29 0 1 50 2 3 52 6 12 55 7 9 54 4 5 56 8 16 53 10 18 57 11 19 58 13 20 59 14 27 60 15 31 61 17 33 62 21 35 63 23 37 66 24 38 68 25 39 69 26 44 71 22 51 73 28 36 65 29 64 76 30 70 78 32 67 77 34 72 79 40 74 80 41 84 85 42 75 81 45 88 92 46 89 93 48 87 91
result:
ok count=29
Test #67:
score: 0
Accepted
time: 2ms
memory: 14088kb
input:
96 2 3 2 1 1 1 1 3 3 2 2 1 2 1 3 3 3 2 3 2 1 3 2 1 2 3 2 2 3 2 1 2 2 1 1 3 1 2 3 3 3 3 3 1 1 2 1 1 2 2 2 1 3 3 1 1 3 2 3 1 1 3 2 1 1 1 2 1 3 2 2 3 3 2 2 3 3 1 1 1 3 1 3 3 3 3 1 3 3 2 2 2 1 1 1 2
output:
28 3 9 53 1 2 54 4 10 52 6 17 56 5 19 58 7 12 55 8 22 59 13 26 61 14 27 63 15 29 64 16 31 65 18 32 67 20 37 68 11 45 71 21 24 60 23 48 72 28 57 77 30 50 76 25 62 78 33 49 75 34 69 80 35 66 79 36 73 82 38 70 81 40 89 92 41 90 93 42 91 94 43 74 83
result:
ok count=28
Test #68:
score: 0
Accepted
time: 0ms
memory: 14124kb
input:
98 2 3 2 1 2 2 1 3 3 3 2 1 3 1 1 2 2 2 2 1 1 2 2 1 2 1 3 2 1 3 3 1 2 1 2 1 1 3 2 1 2 3 1 2 3 3 3 3 2 2 3 1 3 2 1 1 1 3 3 1 3 2 2 1 3 1 3 3 3 1 1 2 1 1 2 3 2 3 2 1 3 1 1 2 3 1 3 3 2 3 3 1 3 1 3 1 3 2
output:
27 1 2 55 6 10 57 3 4 58 7 15 56 8 16 59 9 18 63 11 17 60 12 22 65 13 21 64 14 24 66 19 27 67 20 32 68 26 40 72 28 48 75 29 43 73 25 49 77 30 38 70 33 61 80 36 74 84 37 71 82 39 78 86 41 76 85 42 83 87 35 88 89 44 62 81 23 34 45 46 53 79
result:
ok count=27
Test #69:
score: 0
Accepted
time: 2ms
memory: 14088kb
input:
100 1 3 1 3 1 1 2 3 1 2 2 2 1 3 3 3 3 1 2 3 1 1 3 2 2 2 3 3 2 1 1 3 1 3 2 2 1 1 1 3 1 3 2 3 2 2 2 1 3 3 1 1 1 1 1 3 2 2 2 3 3 2 1 3 2 3 3 1 1 1 2 2 2 2 2 1 1 3 2 3 2 3 1 3 1 1 3 3 2 1 2 2 3 3 3 3 1 1 3 1
output:
30 1 9 51 3 11 53 5 23 55 4 24 59 7 18 54 8 25 60 12 34 63 13 28 62 2 10 65 14 35 52 0 6 66 15 42 50 16 44 67 19 46 69 21 58 77 22 57 76 20 61 79 26 56 75 17 64 81 27 45 68 30 71 83 31 72 84 32 74 86 33 73 85 36 78 87 38 88 92 37 90 93 39 80 89 40 91 94 41 70 82
result:
ok count=30
Test #70:
score: 0
Accepted
time: 0ms
memory: 14088kb
input:
100 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 3 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
output:
1 0 29 58
result:
ok count=1
Test #71:
score: 0
Accepted
time: 0ms
memory: 14224kb
input:
100 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 2 2 2 2 2 2 1 2 2 2 2 2 2
output:
1 29 30 93
result:
ok count=1
Test #72:
score: 0
Accepted
time: 2ms
memory: 12136kb
input:
99 1 1 3 3 2 1 2 2 2 2 1 2 1 3 1 3 3 1 3 3 2 2 2 1 2 2 2 2 2 2 1 2 1 2 3 2 3 2 1 2 1 3 1 2 2 1 2 3 2 2 1 3 2 1 2 3 2 2 1 2 3 1 1 3 3 3 3 3 3 1 1 3 1 3 1 1 1 3 1 1 3 1 3 3 1 3 3 3 2 1 1 3 3 2 3 3 1 2 1
output:
33 0 4 63 1 6 64 5 9 67 10 11 68 3 8 69 12 20 66 13 21 70 14 22 71 15 24 72 16 26 74 17 25 73 18 27 75 19 28 76 23 29 77 2 7 78 30 31 65 32 33 80 34 35 79 36 37 81 38 39 82 40 43 83 41 44 84 42 46 85 45 48 86 47 49 89 50 52 87 51 54 90 53 56 91 58 59 94 60 93 96 61 88 95 55 57 62 92 97 98
result:
ok count=33
Test #73:
score: 0
Accepted
time: 0ms
memory: 12276kb
input:
96 3 2 1 2 3 1 2 1 2 1 2 2 1 1 2 2 3 2 1 3 2 2 1 2 3 2 1 2 3 3 3 3 1 2 2 2 2 2 1 1 1 1 3 1 2 1 1 3 3 1 3 3 1 3 3 1 1 1 3 3 3 1 3 1 1 3 3 1 3 3 3 3 2 1 2 3 2 3 2 3 2 1 2 1 2 3 2 3 2 1 2 3 2 1 2 1
output:
32 0 1 52 2 3 53 4 8 55 5 6 54 12 14 58 13 15 59 9 11 60 16 17 57 18 21 62 19 20 61 24 25 64 26 27 65 22 23 66 28 33 63 29 34 67 7 10 68 30 35 56 32 37 70 38 44 71 31 36 39 69 72 73 40 74 75 41 76 77 42 80 81 43 78 79 46 84 85 45 86 87 47 82 83 48 88 89 49 90 91 50 92 93 51 94 95
result:
ok count=32
Test #74:
score: 0
Accepted
time: 2ms
memory: 12044kb
input:
99 3 2 1 2 1 1 1 3 2 3 1 2 1 2 3 3 3 1 3 3 3 1 1 3 3 3 3 3 1 3 1 1 1 1 1 3 1 1 1 1 1 1 3 2 3 2 3 2 2 3 1 2 2 2 2 3 2 1 1 1 3 2 3 2 2 2 3 1 3 2 1 2 3 2 2 2 2 2 2 2 1 1 3 1 1 3 3 2 3 2 2 2 3 2 2 3 1 3 1
output:
33 0 1 38 6 13 42 5 43 44 7 11 41 4 8 9 40 45 46 10 47 49 12 51 55 14 48 50 15 52 57 16 53 58 17 56 60 18 54 59 2 3 19 39 61 62 20 64 67 21 63 66 22 65 68 23 69 70 25 73 80 26 74 81 27 76 83 28 75 82 29 77 84 30 78 85 31 79 86 32 87 88 33 89 92 34 90 95 35 91 96 36 93 97 24 94 98 37 71 72
result:
ok count=33
Test #75:
score: 0
Accepted
time: 0ms
memory: 12264kb
input:
93 3 2 3 2 3 2 1 2 3 2 3 2 3 2 3 1 3 1 3 1 1 1 3 3 1 3 3 3 1 1 3 1 1 1 3 3 1 3 3 1 2 2 3 1 1 2 3 2 1 3 3 1 3 2 2 2 2 2 2 2 3 2 3 3 1 1 1 3 1 2 2 3 1 2 1 2 1 2 3 2 2 1 1 2 2 2 2 2 3 1 1 1 1
output:
31 2 3 39 4 5 43 6 7 42 8 9 44 12 13 48 15 41 50 16 45 51 17 47 52 19 54 62 20 55 63 18 56 64 21 53 60 22 57 65 23 58 66 24 59 67 25 61 68 27 70 72 26 73 74 28 69 71 14 75 76 29 40 49 30 79 81 31 77 78 10 11 32 46 80 82 33 83 88 34 84 89 35 85 90 0 1 36 38 86 91 37 87 92
result:
ok count=31
Test #76:
score: 0
Accepted
time: 0ms
memory: 12080kb
input:
90 3 3 3 3 2 2 2 2 3 2 1 2 3 2 3 2 1 1 2 2 3 3 2 2 1 3 2 2 1 2 1 1 3 1 3 2 3 3 3 1 1 1 3 1 3 2 3 1 1 3 1 2 1 1 3 3 3 1 2 1 1 2 1 3 3 3 1 1 3 1 2 2 1 2 1 3 2 3 2 2 3 1 2 1 2 1 2 1 2 3
output:
30 0 4 47 1 5 48 3 7 50 8 9 52 2 6 53 10 11 49 16 18 56 14 15 57 17 19 55 20 22 59 21 23 60 12 13 62 24 26 54 28 29 64 30 35 65 25 27 66 31 45 63 32 51 67 33 58 68 34 61 69 36 70 72 37 71 74 39 76 77 40 78 80 38 79 81 41 73 75 42 82 83 44 86 87 43 88 89 46 84 85
result:
ok count=30
Test #77:
score: 0
Accepted
time: 2ms
memory: 14108kb
input:
100 2 1 2 2 2 3 2 2 1 2 1 2 2 1 2 2 2 2 1 2 2 3 2 2 2 2 2 1 2 2 2 3 3 1 1 1 1 1 1 1 3 3 3 1 1 3 1 1 1 1 3 3 3 1 3 3 3 1 1 3 1 3 1 3 3 3 2 3 2 2 1 2 2 3 2 2 2 2 2 2 3 1 2 1 1 1 1 2 2 3 2 2 3 2 2 2 2 1 2 2
output:
20 1 2 54 8 9 56 5 6 57 10 11 55 18 19 59 21 22 60 27 28 61 13 14 31 58 66 67 32 68 70 33 69 73 34 71 80 39 78 89 40 77 86 38 79 92 41 76 85 42 82 97 45 72 81 50 74 83 51 75 84
result:
ok count=20
Test #78:
score: 0
Accepted
time: 0ms
memory: 14104kb
input:
99 2 2 2 2 2 2 2 1 2 1 2 2 2 2 2 2 3 2 2 2 2 2 3 2 1 2 3 2 2 2 2 2 2 1 1 1 1 1 3 3 1 1 3 3 1 1 3 1 1 3 3 1 1 1 3 3 1 1 3 1 1 1 3 3 3 3 3 2 2 3 3 1 2 3 2 2 2 1 2 1 3 1 1 2 1 2 1 1 1 2 3 2 2 2 2 2 1 1 2
output:
18 9 10 62 16 17 61 7 8 63 22 23 60 24 25 64 33 67 69 34 68 70 35 72 73 26 27 36 65 74 77 37 76 80 38 75 79 39 78 81 41 89 90 42 85 86 43 91 96 46 83 84 49 92 97
result:
ok count=18
Test #79:
score: 0
Accepted
time: 2ms
memory: 11984kb
input:
98 3 2 2 2 2 2 2 3 3 2 2 2 1 2 1 2 2 2 2 2 2 3 1 3 1 3 2 3 2 1 2 2 1 1 1 3 3 3 3 1 3 1 1 1 3 3 1 3 3 3 1 3 1 3 3 1 3 3 1 1 3 3 3 3 2 2 2 2 2 2 2 2 2 1 3 2 2 2 3 2 2 2 2 3 2 1 2 2 2 2 2 2 2 2 2 2 2 1
output:
15 0 1 41 7 9 42 8 10 43 12 13 44 14 15 45 21 26 46 22 28 47 24 31 49 25 64 73 29 66 78 32 67 83 27 68 85 33 65 74 23 30 34 48 69 97
result:
ok count=15
Test #80:
score: 0
Accepted
time: 0ms
memory: 14256kb
input:
97 2 2 1 3 2 2 1 2 2 2 1 2 1 1 1 1 2 2 3 2 3 1 2 2 2 3 2 3 3 2 2 2 1 3 1 1 1 1 1 1 1 1 3 3 3 1 3 1 1 1 1 3 1 1 1 3 1 3 1 3 1 1 3 1 2 2 1 2 1 2 2 2 2 2 1 3 2 2 1 3 1 2 3 1 2 2 1 2 2 2 2 3 3 2 2 1 1
output:
21 2 4 57 3 5 58 6 7 59 13 17 62 18 23 68 20 24 74 21 26 75 25 29 78 15 22 79 27 30 66 28 31 80 32 64 82 33 65 83 35 69 91 36 70 92 10 11 42 12 16 43 14 19 44 46 67 86 51 71 95 55 72 96
result:
ok count=21
Test #81:
score: 0
Accepted
time: 1ms
memory: 10092kb
input:
99 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3
output:
33 0 33 66 1 34 67 2 35 68 3 36 69 4 37 70 5 38 71 6 39 72 7 40 73 8 41 74 9 42 75 10 43 76 11 44 77 12 45 78 13 46 79 14 47 80 15 48 81 16 49 82 17 50 83 18 51 84 19 52 85 20 53 86 21 54 87 22 55 88 23 56 89 24 57 90 25 58 91 26 59 92 27 60 93 28 61 94 29 62 95 30 63 96 31 64 97 32 65 98
result:
ok count=33
Test #82:
score: 0
Accepted
time: 0ms
memory: 12040kb
input:
99 3 2 3 3 1 2 1 1 1 1 2 2 3 1 3 1 3 3 2 3 3 2 3 3 1 2 3 3 1 1 1 2 1 1 1 1 3 1 1 2 1 2 1 2 3 3 2 3 1 2 2 1 2 3 3 3 1 3 2 2 2 2 2 2 2 2 3 3 1 2 2 2 1 3 3 1 3 2 2 3 2 2 3 2 1 2 1 3 1 3 3 1 2 1 1 3 1 3 1
output:
33 3 11 48 4 10 47 2 5 51 6 18 45 7 21 53 8 25 54 9 31 55 12 39 56 13 41 57 15 46 67 16 49 68 17 50 72 22 59 75 24 61 79 27 63 84 26 64 86 28 62 82 29 65 87 23 69 88 30 60 76 32 70 89 33 71 90 20 77 91 34 58 74 19 78 93 35 52 73 36 80 94 37 81 95 14 83 96 38 43 66 40 85 97 0 1 42 44 92 98
result:
ok count=33
Test #83:
score: 0
Accepted
time: 2ms
memory: 12052kb
input:
96 3 3 3 2 2 1 2 3 1 3 3 1 3 2 1 2 1 3 2 1 2 1 2 1 2 2 2 1 1 1 3 2 3 3 3 3 1 2 3 3 1 1 3 2 3 1 3 1 2 3 1 3 2 2 2 1 1 1 2 2 1 1 2 3 3 2 1 2 2 1 2 2 2 3 3 3 1 3 3 2 2 3 1 3 2 1 2 3 1 1 2 3 1 1 1 3
output:
32 1 4 47 2 13 50 5 6 49 7 18 55 8 15 51 9 20 56 10 22 57 0 3 60 11 24 46 12 25 61 14 26 63 16 31 64 17 37 66 21 48 73 23 52 74 27 53 75 29 58 77 28 59 78 30 54 76 19 62 81 32 43 69 33 65 82 35 68 85 36 70 87 38 71 88 39 72 89 40 79 91 34 80 92 41 67 83 42 84 93 44 86 94 45 90 95
result:
ok count=32
Test #84:
score: 0
Accepted
time: 3ms
memory: 16396kb
input:
3000 2 3 2 3 3 1 2 3 1 3 2 1 1 2 3 2 2 2 3 1 2 1 3 2 3 2 1 2 3 3 2 1 3 3 3 3 3 3 2 1 1 2 2 1 1 2 3 1 1 2 2 3 3 1 2 2 3 2 1 1 1 3 1 2 2 3 3 1 1 1 3 2 1 2 1 3 2 2 1 1 2 3 3 3 3 2 3 1 2 2 3 2 3 1 3 3 3 3 1 3 2 2 2 2 1 3 2 2 2 1 2 2 3 2 2 1 1 1 1 1 2 3 2 1 2 3 3 3 2 3 3 3 3 2 3 2 2 2 2 1 3 3 1 1 1 1 2 3...
output:
999 1 2 1481 4 13 1485 5 10 1483 8 16 1487 9 17 1488 11 20 1489 12 23 1490 18 27 1492 14 30 1493 19 25 1491 21 38 1495 22 41 1498 24 42 1499 7 15 1503 26 45 1486 28 49 1504 29 54 1507 31 50 1505 35 64 1519 36 71 1520 37 73 1522 34 76 1523 39 63 1517 33 77 1524 40 57 1514 32 80 1527 43 55 1510 44 85 ...
result:
ok count=999
Test #85:
score: 0
Accepted
time: 0ms
memory: 14112kb
input:
2997 1 3 1 3 2 1 3 3 2 2 2 1 1 2 3 3 3 1 3 2 3 3 2 1 2 3 1 2 2 2 2 1 3 3 2 1 2 2 3 2 2 2 2 1 3 1 3 3 3 3 1 3 3 1 3 1 3 2 3 1 2 3 1 2 2 3 3 1 3 3 3 3 3 3 1 1 1 3 3 1 3 3 1 1 1 3 2 3 3 2 3 3 3 1 3 3 2 1 1 1 2 1 1 1 1 3 3 3 3 2 3 1 3 3 2 1 3 1 3 1 1 3 2 1 2 3 1 2 2 2 3 1 3 2 2 3 2 3 3 3 1 2 3 2 1 1 3 1...
output:
995 1 8 1488 2 10 1490 3 9 1489 5 19 1493 6 13 1491 7 22 1495 12 28 1498 14 27 1497 15 29 1499 16 30 1500 18 36 1502 20 37 1504 21 39 1505 23 40 1506 25 41 1507 31 57 1511 26 60 1514 32 42 1509 17 63 1515 33 34 1501 35 64 1516 11 24 1517 38 86 1496 44 96 1520 45 109 1527 46 100 1526 47 114 1529 43 1...
result:
ok count=995
Test #86:
score: 0
Accepted
time: 0ms
memory: 14104kb
input:
18 2 1 2 2 2 2 1 3 1 3 3 3 2 2 2 2 3 2
output:
2 6 12 16 1 2 7
result:
ok count=2
Test #87:
score: 0
Accepted
time: 0ms
memory: 14052kb
input:
17 1 2 2 2 2 1 1 1 1 3 2 2 1 2 1 2 2
output:
1 0 1 9
result:
ok count=1
Test #88:
score: 0
Accepted
time: 2ms
memory: 14120kb
input:
16 1 2 2 2 2 3 3 1 3 3 2 2 2 2 3 2
output:
2 0 1 6 7 10 14
result:
ok count=2
Test #89:
score: 0
Accepted
time: 0ms
memory: 14124kb
input:
90 3 2 3 2 2 1 1 3 2 2 1 1 1 1 1 2 2 1 2 3 3 3 3 3 1 1 3 2 3 2 3 2 3 2 2 3 3 2 1 2 2 2 2 1 3 1 3 3 1 1 1 2 3 1 1 2 3 3 2 3 3 2 2 2 1 2 1 2 1 3 2 3 3 3 1 1 2 1 1 3 1 3 1 1 2 2 1 3 1 3
output:
29 0 1 48 2 3 49 6 9 52 7 15 53 11 18 56 12 27 57 13 29 59 14 31 60 19 34 66 20 37 68 17 39 69 21 33 64 10 16 71 22 40 54 5 8 72 23 41 50 24 42 73 26 55 75 28 58 77 30 61 78 25 62 79 32 51 74 35 63 80 36 67 82 38 65 81 44 76 86 45 84 87 46 85 88 47 70 83
result:
ok count=29
Test #90:
score: 0
Accepted
time: 0ms
memory: 11984kb
input:
15 2 3 3 2 1 3 2 1 1 1 3 2 3 1 2
output:
3 1 3 8 2 6 9 4 11 12
result:
ok count=3
Test #91:
score: 0
Accepted
time: 0ms
memory: 12136kb
input:
18 3 3 3 1 1 3 2 2 1 2 1 2 3 2 2 1 3 1
output:
6 0 6 8 1 7 10 2 11 15 3 9 12 4 13 16 5 14 17
result:
ok count=6
Test #92:
score: 0
Accepted
time: 2ms
memory: 12208kb
input:
16 1 3 3 2 1 3 1 2 2 2 3 1 3 2 1 2
output:
5 0 7 10 1 3 6 2 8 11 4 9 12 5 13 14
result:
ok count=5
Test #93:
score: 0
Accepted
time: 0ms
memory: 11988kb
input:
15 1 3 1 2 3 2 3 3 2 1 2 2 1 1 3
output:
5 0 3 7 1 5 9 4 10 13 2 11 14 6 8 12
result:
ok count=5
Test #94:
score: 0
Accepted
time: 0ms
memory: 11980kb
input:
18 1 3 1 3 2 1 1 3 2 2 2 3 2 3 2 1 1 3
output:
6 0 4 7 2 9 13 3 10 15 1 12 16 5 8 11 6 14 17
result:
ok count=6
Test #95:
score: 0
Accepted
time: 2ms
memory: 11980kb
input:
18 1 3 3 2 1 1 1 2 3 2 1 1 2 3 2 3 2 3
output:
6 0 3 8 1 7 10 2 9 11 4 12 13 5 14 15 6 16 17
result:
ok count=6
Test #96:
score: 0
Accepted
time: 0ms
memory: 12040kb
input:
18 1 2 1 2 3 2 3 3 2 2 3 1 1 3 3 1 2 1
output:
6 2 3 13 4 5 12 0 1 14 6 8 11 7 9 15 10 16 17
result:
ok count=6
Test #97:
score: 0
Accepted
time: 2ms
memory: 12040kb
input:
15 1 2 1 2 3 3 1 1 1 2 3 2 3 2 3
output:
5 2 3 4 8 9 10 0 1 5 7 11 12 6 13 14
result:
ok count=5
Test #98:
score: 0
Accepted
time: 2ms
memory: 12076kb
input:
18 3 2 1 2 1 3 3 1 1 3 2 1 2 3 2 1 2 3
output:
6 0 1 8 2 3 9 4 12 13 5 10 11 6 14 15 7 16 17
result:
ok count=6
Test #99:
score: 0
Accepted
time: 2ms
memory: 12056kb
input:
15 1 2 3 2 3 3 3 1 3 2 1 2 1 2 1
output:
5 0 1 8 2 3 7 4 9 10 5 11 12 6 13 14
result:
ok count=5
Test #100:
score: 0
Accepted
time: 2ms
memory: 12060kb
input:
91 2 1 2 2 1 3 1 2 1 2 2 1 2 3 3 1 2 2 2 1 3 1 3 1 1 3 1 2 1 2 1 3 1 1 3 2 3 1 2 3 2 2 2 2 1 2 1 1 3 2 2 2 1 1 2 3 3 2 3 3 3 3 1 1 3 2 3 3 1 3 3 3 3 3 2 1 2 2 2 3 2 3 2 1 3 1 3 1 3 1 1
output:
29 4 9 55 5 7 53 6 10 56 8 12 58 11 16 59 1 2 60 13 17 52 14 27 62 15 18 61 19 35 64 20 29 63 21 38 66 22 41 68 23 40 67 24 42 69 26 45 71 28 49 72 30 50 73 31 51 75 32 54 79 33 57 81 34 65 83 36 76 85 37 74 84 39 78 87 44 77 86 46 80 88 25 43 47 70 82 89
result:
ok count=29
Test #101:
score: 0
Accepted
time: 0ms
memory: 12044kb
input:
92 3 1 3 3 3 3 3 1 3 2 1 3 3 3 1 1 1 2 2 1 2 1 2 2 2 3 2 1 3 3 2 3 3 2 3 3 2 3 3 2 2 1 2 2 3 3 2 2 2 3 2 1 3 2 1 2 1 1 1 1 1 3 1 3 1 2 1 1 2 2 2 2 3 1 1 3 2 1 1 1 1 1 1 3 1 2 2 3 3 2 2 2
output:
29 1 17 49 2 18 51 4 22 54 5 23 56 6 24 57 3 26 58 7 20 52 8 30 59 0 9 60 10 33 45 12 39 62 13 42 64 14 40 63 11 43 66 15 36 61 19 47 72 25 50 74 27 53 75 28 55 77 29 65 78 31 68 79 32 69 80 34 70 81 35 71 82 21 76 83 37 48 73 16 85 87 38 46 67 41 86 88
result:
ok count=29
Test #102:
score: 0
Accepted
time: 2ms
memory: 14324kb
input:
93 1 1 3 1 1 3 1 1 2 3 1 1 1 2 3 3 2 1 1 3 1 3 3 2 3 3 1 3 2 2 3 3 1 3 1 1 1 2 2 3 1 2 3 1 3 3 2 3 2 3 2 3 2 3 2 3 3 2 1 3 2 2 1 1 1 2 1 1 2 2 2 1 1 2 3 1 2 2 3 3 2 1 2 2 1 2 2 2 2 3 3 2 2
output:
28 1 13 39 2 16 40 3 23 42 4 29 44 5 28 43 6 37 45 7 38 47 0 8 9 36 41 49 10 46 51 11 48 53 12 50 55 15 54 58 17 57 59 14 60 62 18 52 56 19 61 63 21 68 71 22 69 72 20 70 74 24 65 66 25 73 75 26 76 78 30 80 81 31 82 84 32 83 89 34 77 79 35 85 90
result:
ok count=28
Test #103:
score: 0
Accepted
time: 0ms
memory: 12056kb
input:
94 3 3 1 1 3 2 1 3 2 1 2 1 1 2 2 2 2 3 2 2 1 1 3 1 2 1 2 3 3 3 2 2 1 3 2 1 2 2 1 2 3 1 2 1 2 1 3 1 3 1 3 3 2 2 2 1 1 3 2 2 3 3 3 2 2 3 3 3 2 3 2 1 2 2 1 1 2 1 1 1 3 2 2 1 3 3 1 3 1 3 3 3 2 1
output:
30 0 5 49 2 10 51 1 13 55 3 8 50 4 14 56 6 15 57 9 18 61 11 19 62 12 24 65 20 30 67 21 31 69 22 34 71 17 36 74 23 26 66 7 16 75 25 37 60 27 39 77 28 42 78 29 44 79 32 52 80 33 53 83 35 54 84 38 58 85 40 59 86 41 63 87 45 68 89 43 70 90 46 64 88 47 72 91 48 73 93
result:
ok count=30
Test #104:
score: 0
Accepted
time: 2ms
memory: 14256kb
input:
94 3 2 3 2 1 2 1 3 3 2 1 3 2 3 1 3 2 1 2 2 2 3 3 1 3 3 1 2 1 1 1 2 3 2 1 2 2 2 2 2 3 1 3 3 2 3 3 3 1 1 1 2 1 1 1 3 3 3 1 1 3 1 3 1 2 3 3 2 1 1 2 3 2 1 2 2 3 1 3 3 1 1 1 3 2 3 1 2 2 2 2 3 1 1
output:
29 0 1 50 2 3 52 6 12 55 7 9 54 4 5 56 8 16 53 10 18 57 11 19 58 13 20 59 14 27 60 15 31 61 17 33 62 21 35 63 23 37 66 24 38 68 25 39 69 26 44 71 22 51 73 28 36 65 29 64 76 30 70 78 32 67 77 34 72 79 40 74 80 41 84 85 42 75 81 45 88 92 46 89 93 48 87 91
result:
ok count=29
Test #105:
score: 0
Accepted
time: 2ms
memory: 14032kb
input:
96 2 3 2 1 1 1 1 3 3 2 2 1 2 1 3 3 3 2 3 2 1 3 2 1 2 3 2 2 3 2 1 2 2 1 1 3 1 2 3 3 3 3 3 1 1 2 1 1 2 2 2 1 3 3 1 1 3 2 3 1 1 3 2 1 1 1 2 1 3 2 2 3 3 2 2 3 3 1 1 1 3 1 3 3 3 3 1 3 3 2 2 2 1 1 1 2
output:
28 3 9 53 1 2 54 4 10 52 6 17 56 5 19 58 7 12 55 8 22 59 13 26 61 14 27 63 15 29 64 16 31 65 18 32 67 20 37 68 11 45 71 21 24 60 23 48 72 28 57 77 30 50 76 25 62 78 33 49 75 34 69 80 35 66 79 36 73 82 38 70 81 40 89 92 41 90 93 42 91 94 43 74 83
result:
ok count=28
Test #106:
score: 0
Accepted
time: 0ms
memory: 14032kb
input:
98 2 3 2 1 2 2 1 3 3 3 2 1 3 1 1 2 2 2 2 1 1 2 2 1 2 1 3 2 1 3 3 1 2 1 2 1 1 3 2 1 2 3 1 2 3 3 3 3 2 2 3 1 3 2 1 1 1 3 3 1 3 2 2 1 3 1 3 3 3 1 1 2 1 1 2 3 2 3 2 1 3 1 1 2 3 1 3 3 2 3 3 1 3 1 3 1 3 2
output:
27 1 2 55 6 10 57 3 4 58 7 15 56 8 16 59 9 18 63 11 17 60 12 22 65 13 21 64 14 24 66 19 27 67 20 32 68 26 40 72 28 48 75 29 43 73 25 49 77 30 38 70 33 61 80 36 74 84 37 71 82 39 78 86 41 76 85 42 83 87 35 88 89 44 62 81 23 34 45 46 53 79
result:
ok count=27
Test #107:
score: 0
Accepted
time: 2ms
memory: 14124kb
input:
100 1 3 1 3 1 1 2 3 1 2 2 2 1 3 3 3 3 1 2 3 1 1 3 2 2 2 3 3 2 1 1 3 1 3 2 2 1 1 1 3 1 3 2 3 2 2 2 1 3 3 1 1 1 1 1 3 2 2 2 3 3 2 1 3 2 3 3 1 1 1 2 2 2 2 2 1 1 3 2 3 2 3 1 3 1 1 3 3 2 1 2 2 3 3 3 3 1 1 3 1
output:
30 1 9 51 3 11 53 5 23 55 4 24 59 7 18 54 8 25 60 12 34 63 13 28 62 2 10 65 14 35 52 0 6 66 15 42 50 16 44 67 19 46 69 21 58 77 22 57 76 20 61 79 26 56 75 17 64 81 27 45 68 30 71 83 31 72 84 32 74 86 33 73 85 36 78 87 38 88 92 37 90 93 39 80 89 40 91 94 41 70 82
result:
ok count=30
Test #108:
score: 0
Accepted
time: 0ms
memory: 14104kb
input:
100 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 3 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
output:
1 0 29 58
result:
ok count=1
Test #109:
score: 0
Accepted
time: 0ms
memory: 14144kb
input:
100 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 2 2 2 2 2 2 1 2 2 2 2 2 2
output:
1 29 30 93
result:
ok count=1
Test #110:
score: 0
Accepted
time: 2ms
memory: 12276kb
input:
99 1 1 3 3 2 1 2 2 2 2 1 2 1 3 1 3 3 1 3 3 2 2 2 1 2 2 2 2 2 2 1 2 1 2 3 2 3 2 1 2 1 3 1 2 2 1 2 3 2 2 1 3 2 1 2 3 2 2 1 2 3 1 1 3 3 3 3 3 3 1 1 3 1 3 1 1 1 3 1 1 3 1 3 3 1 3 3 3 2 1 1 3 3 2 3 3 1 2 1
output:
33 0 4 63 1 6 64 5 9 67 10 11 68 3 8 69 12 20 66 13 21 70 14 22 71 15 24 72 16 26 74 17 25 73 18 27 75 19 28 76 23 29 77 2 7 78 30 31 65 32 33 80 34 35 79 36 37 81 38 39 82 40 43 83 41 44 84 42 46 85 45 48 86 47 49 89 50 52 87 51 54 90 53 56 91 58 59 94 60 93 96 61 88 95 55 57 62 92 97 98
result:
ok count=33
Test #111:
score: 0
Accepted
time: 0ms
memory: 12104kb
input:
96 3 2 1 2 3 1 2 1 2 1 2 2 1 1 2 2 3 2 1 3 2 2 1 2 3 2 1 2 3 3 3 3 1 2 2 2 2 2 1 1 1 1 3 1 2 1 1 3 3 1 3 3 1 3 3 1 1 1 3 3 3 1 3 1 1 3 3 1 3 3 3 3 2 1 2 3 2 3 2 3 2 1 2 1 2 3 2 3 2 1 2 3 2 1 2 1
output:
32 0 1 52 2 3 53 4 8 55 5 6 54 12 14 58 13 15 59 9 11 60 16 17 57 18 21 62 19 20 61 24 25 64 26 27 65 22 23 66 28 33 63 29 34 67 7 10 68 30 35 56 32 37 70 38 44 71 31 36 39 69 72 73 40 74 75 41 76 77 42 80 81 43 78 79 46 84 85 45 86 87 47 82 83 48 88 89 49 90 91 50 92 93 51 94 95
result:
ok count=32
Test #112:
score: 0
Accepted
time: 2ms
memory: 12044kb
input:
99 3 2 1 2 1 1 1 3 2 3 1 2 1 2 3 3 3 1 3 3 3 1 1 3 3 3 3 3 1 3 1 1 1 1 1 3 1 1 1 1 1 1 3 2 3 2 3 2 2 3 1 2 2 2 2 3 2 1 1 1 3 2 3 2 2 2 3 1 3 2 1 2 3 2 2 2 2 2 2 2 1 1 3 1 1 3 3 2 3 2 2 2 3 2 2 3 1 3 1
output:
33 0 1 38 6 13 42 5 43 44 7 11 41 4 8 9 40 45 46 10 47 49 12 51 55 14 48 50 15 52 57 16 53 58 17 56 60 18 54 59 2 3 19 39 61 62 20 64 67 21 63 66 22 65 68 23 69 70 25 73 80 26 74 81 27 76 83 28 75 82 29 77 84 30 78 85 31 79 86 32 87 88 33 89 92 34 90 95 35 91 96 36 93 97 24 94 98 37 71 72
result:
ok count=33
Test #113:
score: 0
Accepted
time: 2ms
memory: 12140kb
input:
93 3 2 3 2 3 2 1 2 3 2 3 2 3 2 3 1 3 1 3 1 1 1 3 3 1 3 3 3 1 1 3 1 1 1 3 3 1 3 3 1 2 2 3 1 1 2 3 2 1 3 3 1 3 2 2 2 2 2 2 2 3 2 3 3 1 1 1 3 1 2 2 3 1 2 1 2 1 2 3 2 2 1 1 2 2 2 2 2 3 1 1 1 1
output:
31 2 3 39 4 5 43 6 7 42 8 9 44 12 13 48 15 41 50 16 45 51 17 47 52 19 54 62 20 55 63 18 56 64 21 53 60 22 57 65 23 58 66 24 59 67 25 61 68 27 70 72 26 73 74 28 69 71 14 75 76 29 40 49 30 79 81 31 77 78 10 11 32 46 80 82 33 83 88 34 84 89 35 85 90 0 1 36 38 86 91 37 87 92
result:
ok count=31
Test #114:
score: 0
Accepted
time: 2ms
memory: 12080kb
input:
90 3 3 3 3 2 2 2 2 3 2 1 2 3 2 3 2 1 1 2 2 3 3 2 2 1 3 2 2 1 2 1 1 3 1 3 2 3 3 3 1 1 1 3 1 3 2 3 1 1 3 1 2 1 1 3 3 3 1 2 1 1 2 1 3 3 3 1 1 3 1 2 2 1 2 1 3 2 3 2 2 3 1 2 1 2 1 2 1 2 3
output:
30 0 4 47 1 5 48 3 7 50 8 9 52 2 6 53 10 11 49 16 18 56 14 15 57 17 19 55 20 22 59 21 23 60 12 13 62 24 26 54 28 29 64 30 35 65 25 27 66 31 45 63 32 51 67 33 58 68 34 61 69 36 70 72 37 71 74 39 76 77 40 78 80 38 79 81 41 73 75 42 82 83 44 86 87 43 88 89 46 84 85
result:
ok count=30
Test #115:
score: 0
Accepted
time: 0ms
memory: 14320kb
input:
100 2 1 2 2 2 3 2 2 1 2 1 2 2 1 2 2 2 2 1 2 2 3 2 2 2 2 2 1 2 2 2 3 3 1 1 1 1 1 1 1 3 3 3 1 1 3 1 1 1 1 3 3 3 1 3 3 3 1 1 3 1 3 1 3 3 3 2 3 2 2 1 2 2 3 2 2 2 2 2 2 3 1 2 1 1 1 1 2 2 3 2 2 3 2 2 2 2 1 2 2
output:
20 1 2 54 8 9 56 5 6 57 10 11 55 18 19 59 21 22 60 27 28 61 13 14 31 58 66 67 32 68 70 33 69 73 34 71 80 39 78 89 40 77 86 38 79 92 41 76 85 42 82 97 45 72 81 50 74 83 51 75 84
result:
ok count=20
Test #116:
score: 0
Accepted
time: 0ms
memory: 14100kb
input:
99 2 2 2 2 2 2 2 1 2 1 2 2 2 2 2 2 3 2 2 2 2 2 3 2 1 2 3 2 2 2 2 2 2 1 1 1 1 1 3 3 1 1 3 3 1 1 3 1 1 3 3 1 1 1 3 3 1 1 3 1 1 1 3 3 3 3 3 2 2 3 3 1 2 3 2 2 2 1 2 1 3 1 1 2 1 2 1 1 1 2 3 2 2 2 2 2 1 1 2
output:
18 9 10 62 16 17 61 7 8 63 22 23 60 24 25 64 33 67 69 34 68 70 35 72 73 26 27 36 65 74 77 37 76 80 38 75 79 39 78 81 41 89 90 42 85 86 43 91 96 46 83 84 49 92 97
result:
ok count=18
Test #117:
score: 0
Accepted
time: 2ms
memory: 12104kb
input:
98 3 2 2 2 2 2 2 3 3 2 2 2 1 2 1 2 2 2 2 2 2 3 1 3 1 3 2 3 2 1 2 2 1 1 1 3 3 3 3 1 3 1 1 1 3 3 1 3 3 3 1 3 1 3 3 1 3 3 1 1 3 3 3 3 2 2 2 2 2 2 2 2 2 1 3 2 2 2 3 2 2 2 2 3 2 1 2 2 2 2 2 2 2 2 2 2 2 1
output:
15 0 1 41 7 9 42 8 10 43 12 13 44 14 15 45 21 26 46 22 28 47 24 31 49 25 64 73 29 66 78 32 67 83 27 68 85 33 65 74 23 30 34 48 69 97
result:
ok count=15
Test #118:
score: 0
Accepted
time: 0ms
memory: 14340kb
input:
97 2 2 1 3 2 2 1 2 2 2 1 2 1 1 1 1 2 2 3 2 3 1 2 2 2 3 2 3 3 2 2 2 1 3 1 1 1 1 1 1 1 1 3 3 3 1 3 1 1 1 1 3 1 1 1 3 1 3 1 3 1 1 3 1 2 2 1 2 1 2 2 2 2 2 1 3 2 2 1 3 1 2 3 1 2 2 1 2 2 2 2 3 3 2 2 1 1
output:
21 2 4 57 3 5 58 6 7 59 13 17 62 18 23 68 20 24 74 21 26 75 25 29 78 15 22 79 27 30 66 28 31 80 32 64 82 33 65 83 35 69 91 36 70 92 10 11 42 12 16 43 14 19 44 46 67 86 51 71 95 55 72 96
result:
ok count=21
Test #119:
score: 0
Accepted
time: 1ms
memory: 10128kb
input:
99 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3
output:
33 0 33 66 1 34 67 2 35 68 3 36 69 4 37 70 5 38 71 6 39 72 7 40 73 8 41 74 9 42 75 10 43 76 11 44 77 12 45 78 13 46 79 14 47 80 15 48 81 16 49 82 17 50 83 18 51 84 19 52 85 20 53 86 21 54 87 22 55 88 23 56 89 24 57 90 25 58 91 26 59 92 27 60 93 28 61 94 29 62 95 30 63 96 31 64 97 32 65 98
result:
ok count=33
Test #120:
score: 0
Accepted
time: 2ms
memory: 12076kb
input:
99 3 2 3 3 1 2 1 1 1 1 2 2 3 1 3 1 3 3 2 3 3 2 3 3 1 2 3 3 1 1 1 2 1 1 1 1 3 1 1 2 1 2 1 2 3 3 2 3 1 2 2 1 2 3 3 3 1 3 2 2 2 2 2 2 2 2 3 3 1 2 2 2 1 3 3 1 3 2 2 3 2 2 3 2 1 2 1 3 1 3 3 1 2 1 1 3 1 3 1
output:
33 3 11 48 4 10 47 2 5 51 6 18 45 7 21 53 8 25 54 9 31 55 12 39 56 13 41 57 15 46 67 16 49 68 17 50 72 22 59 75 24 61 79 27 63 84 26 64 86 28 62 82 29 65 87 23 69 88 30 60 76 32 70 89 33 71 90 20 77 91 34 58 74 19 78 93 35 52 73 36 80 94 37 81 95 14 83 96 38 43 66 40 85 97 0 1 42 44 92 98
result:
ok count=33
Test #121:
score: 0
Accepted
time: 0ms
memory: 12280kb
input:
96 3 3 3 2 2 1 2 3 1 3 3 1 3 2 1 2 1 3 2 1 2 1 2 1 2 2 2 1 1 1 3 2 3 3 3 3 1 2 3 3 1 1 3 2 3 1 3 1 2 3 1 3 2 2 2 1 1 1 2 2 1 1 2 3 3 2 1 2 2 1 2 2 2 3 3 3 1 3 3 2 2 3 1 3 2 1 2 3 1 1 2 3 1 1 1 3
output:
32 1 4 47 2 13 50 5 6 49 7 18 55 8 15 51 9 20 56 10 22 57 0 3 60 11 24 46 12 25 61 14 26 63 16 31 64 17 37 66 21 48 73 23 52 74 27 53 75 29 58 77 28 59 78 30 54 76 19 62 81 32 43 69 33 65 82 35 68 85 36 70 87 38 71 88 39 72 89 40 79 91 34 80 92 41 67 83 42 84 93 44 86 94 45 90 95
result:
ok count=32
Test #122:
score: 0
Accepted
time: 2ms
memory: 14284kb
input:
3000 2 3 2 3 3 1 2 3 1 3 2 1 1 2 3 2 2 2 3 1 2 1 3 2 3 2 1 2 3 3 2 1 3 3 3 3 3 3 2 1 1 2 2 1 1 2 3 1 1 2 2 3 3 1 2 2 3 2 1 1 1 3 1 2 2 3 3 1 1 1 3 2 1 2 1 3 2 2 1 1 2 3 3 3 3 2 3 1 2 2 3 2 3 1 3 3 3 3 1 3 2 2 2 2 1 3 2 2 2 1 2 2 3 2 2 1 1 1 1 1 2 3 2 1 2 3 3 3 2 3 3 3 3 2 3 2 2 2 2 1 3 3 1 1 1 1 2 3...
output:
999 1 2 1481 4 13 1485 5 10 1483 8 16 1487 9 17 1488 11 20 1489 12 23 1490 18 27 1492 14 30 1493 19 25 1491 21 38 1495 22 41 1498 24 42 1499 7 15 1503 26 45 1486 28 49 1504 29 54 1507 31 50 1505 35 64 1519 36 71 1520 37 73 1522 34 76 1523 39 63 1517 33 77 1524 40 57 1514 32 80 1527 43 55 1510 44 85 ...
result:
ok count=999
Test #123:
score: 0
Accepted
time: 0ms
memory: 14060kb
input:
2997 1 3 1 3 2 1 3 3 2 2 2 1 1 2 3 3 3 1 3 2 3 3 2 1 2 3 1 2 2 2 2 1 3 3 2 1 2 2 3 2 2 2 2 1 3 1 3 3 3 3 1 3 3 1 3 1 3 2 3 1 2 3 1 2 2 3 3 1 3 3 3 3 3 3 1 1 1 3 3 1 3 3 1 1 1 3 2 3 3 2 3 3 3 1 3 3 2 1 1 1 2 1 1 1 1 3 3 3 3 2 3 1 3 3 2 1 3 1 3 1 1 3 2 1 2 3 1 2 2 2 3 1 3 2 2 3 2 3 3 3 1 2 3 2 1 1 3 1...
output:
995 1 8 1488 2 10 1490 3 9 1489 5 19 1493 6 13 1491 7 22 1495 12 28 1498 14 27 1497 15 29 1499 16 30 1500 18 36 1502 20 37 1504 21 39 1505 23 40 1506 25 41 1507 31 57 1511 26 60 1514 32 42 1509 17 63 1515 33 34 1501 35 64 1516 11 24 1517 38 86 1496 44 96 1520 45 109 1527 46 100 1526 47 114 1529 43 1...
result:
ok count=995
Test #124:
score: 0
Accepted
time: 0ms
memory: 14100kb
input:
3000 1 1 1 1 1 3 1 1 3 3 1 3 1 1 2 3 1 1 2 1 2 1 3 3 3 1 1 2 1 2 2 3 1 1 1 1 1 1 1 2 1 1 1 1 1 1 2 3 3 1 1 2 1 1 2 1 1 1 1 1 2 1 1 1 1 1 1 2 1 1 1 2 3 1 1 1 1 3 3 2 1 3 1 1 2 3 1 2 3 1 1 1 2 1 1 1 1 2 3 2 1 1 1 1 1 2 1 1 1 1 1 1 1 2 1 1 1 3 1 3 3 1 1 1 1 3 1 1 2 1 1 1 3 3 1 1 1 1 2 1 1 1 1 1 2 3 3 1...
output:
499 0 14 2416 4 29 2420 5 30 2422 7 46 2425 6 51 2426 8 39 2424 9 54 2428 11 67 2430 15 84 2434 19 97 2437 22 105 2440 21 113 2441 23 99 2438 24 128 2443 31 162 2447 35 181 2451 36 188 2452 37 197 2453 47 244 2461 45 249 2462 48 238 2460 59 283 2472 63 296 2475 64 299 2476 66 312 2478 69 318 2480 72...
result:
ok count=499
Test #125:
score: 0
Accepted
time: 0ms
memory: 14156kb
input:
3000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
1 0 1374 2901
result:
ok count=1
Test #126:
score: 0
Accepted
time: 2ms
memory: 9988kb
input:
3000 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2...
output:
1 1755 1756 1874
result:
ok count=1
Test #127:
score: 0
Accepted
time: 2ms
memory: 12116kb
input:
1500 1 1 1 2 1 1 1 2 2 2 2 2 1 1 3 1 2 2 3 1 2 2 2 2 1 2 1 2 1 1 3 1 2 2 2 2 1 1 3 1 1 2 2 3 2 1 3 1 1 2 2 2 1 2 2 2 2 2 1 2 3 2 3 2 3 2 1 3 2 1 2 3 2 2 3 2 3 1 1 3 1 3 1 3 3 3 1 3 3 3 1 1 3 1 3 1 3 1 1 1 3 1 3 1 3 3 1 1 1 3 1 1 3 1 1 1 1 1 3 3 3 3 1 3 1 1 1 1 3 3 3 3 3 3 1 3 1 1 1 3 1 3 1 1 1 1 3 1...
output:
500 1 7 542 4 9 544 5 10 545 12 16 547 14 20 549 15 21 550 18 22 551 26 27 554 29 34 557 30 33 556 31 35 558 36 41 559 38 44 561 40 50 563 39 51 564 43 49 562 45 54 566 46 53 565 58 59 570 60 61 571 62 63 572 52 57 573 64 65 569 66 70 576 67 68 575 69 72 577 71 73 578 74 75 579 48 56 580 76 364 568 ...
result:
ok count=500
Test #128:
score: 0
Accepted
time: 0ms
memory: 12008kb
input:
3000 3 1 1 1 1 3 3 2 1 1 1 2 3 1 3 3 3 3 1 1 3 1 3 3 1 1 1 1 1 3 3 1 1 1 1 3 1 3 1 1 3 3 3 3 1 3 1 3 1 3 1 3 1 1 1 3 3 1 3 1 1 1 3 1 3 3 3 3 1 1 1 1 3 1 1 1 3 3 1 2 3 3 1 3 3 3 3 3 3 3 1 1 1 1 3 1 3 1 3 3 3 3 1 3 1 1 3 3 1 1 1 3 3 1 3 3 1 3 1 3 1 3 2 3 1 3 1 1 3 1 1 1 3 3 1 1 3 3 2 2 2 2 2 2 2 2 2 2...
output:
1000 0 7 1887 1 11 1888 3 122 1890 4 139 1892 5 138 1891 2 140 1893 6 79 1889 8 141 1894 9 142 1895 10 144 1897 12 143 1896 13 146 1900 14 145 1899 17 150 1904 18 149 1903 16 151 1905 19 148 1902 21 153 1907 22 154 1908 23 155 1909 20 156 1910 24 152 1906 25 157 1911 15 158 1912 26 147 1901 27 159 1...
result:
ok count=1000
Test #129:
score: 0
Accepted
time: 2ms
memory: 12056kb
input:
3000 1 3 1 1 3 1 1 1 1 3 1 1 3 1 1 1 3 3 3 3 3 1 1 3 1 1 3 1 3 3 1 2 2 3 1 3 3 3 1 3 3 2 3 1 1 3 3 1 1 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 3 3 3 1 1 1 1 3 1 1 1 3 1 1 1 1 1 3 3 3 3 3 1 3 3 3 1 1 1 3 1 1 3 1 1 3 1 3 3 3 1 1 1 3 3 3 3 3 1 1 1...
output:
1000 0 31 1618 1 32 1619 2 41 1620 4 52 1622 7 55 1625 8 56 1626 9 57 1627 10 58 1628 11 59 1629 12 60 1630 13 61 1631 14 62 1632 15 63 1633 6 64 1634 16 54 1624 5 65 1635 17 53 1623 18 66 1636 3 67 1637 19 51 1621 20 68 1638 22 71 1641 23 70 1640 26 74 1644 28 76 1646 27 77 1647 29 75 1645 33 79 16...
result:
ok count=1000
Test #130:
score: 0
Accepted
time: 0ms
memory: 12060kb
input:
2997 3 1 2 2 1 1 1 1 1 1 3 1 3 3 1 3 3 3 1 3 1 2 1 1 3 1 2 2 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 3 3 1 1 3 1 3 1 1 3 3 1 3 1 3 3 3 1 1 1 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 3 1 3 1 1 1 1 1 3 3 3 1 3 1 1 3 3 3 1 3 3 1 1 1 3 1 1 3 1 1 3 2 3 3 3 2 3 2 3 1 2 1 1 3 1 1 3 2 2 2 2...
output:
999 0 2 1215 6 27 1219 8 31 1221 9 33 1223 10 32 1222 11 34 1224 7 35 1225 12 30 1220 13 36 1226 14 37 1227 15 38 1228 5 39 1229 16 26 1218 4 40 1230 17 21 1217 18 41 1231 19 42 1232 22 44 1234 23 45 1235 20 46 1236 24 43 1233 25 47 1237 51 74 1241 50 75 1242 52 73 1240 55 78 1245 56 79 1246 54 80 1...
result:
ok count=999
Test #131:
score: 0
Accepted
time: 2ms
memory: 14336kb
input:
2994 1 1 2 1 2 1 2 2 3 1 3 3 3 3 1 3 1 1 2 3 3 1 3 3 3 3 1 1 1 3 3 2 3 1 3 1 3 3 1 2 3 1 3 3 3 1 3 1 3 2 3 2 1 1 3 1 1 1 3 2 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 1 1 2 3 3 3 3 3 3 1 3 1 3 1 1 2 1 3 3 3 2 2 3 2 1 3 3 3 1 2 1 1 2 3 3 1 3 2 2 2 2 2 2 2 2...
output:
998 0 2 1925 3 6 1927 5 7 1928 1 4 1929 8 18 1926 9 31 1930 13 59 1934 12 61 1935 14 51 1933 16 63 1937 15 64 1938 17 62 1936 20 66 1940 21 67 1941 22 68 1942 23 69 1943 25 72 1946 26 71 1945 24 73 1947 27 70 1944 19 74 1948 28 65 1939 32 77 1951 33 78 1952 34 79 1953 35 80 1954 36 81 1955 38 83 195...
result:
ok count=998
Test #132:
score: 0
Accepted
time: 0ms
memory: 12208kb
input:
3000 1 1 1 3 2 3 2 3 1 1 1 1 2 3 1 2 1 2 1 3 3 2 2 3 3 2 3 2 2 3 3 3 3 3 1 3 2 1 2 3 2 3 3 3 2 1 3 3 3 2 1 1 1 1 2 1 3 1 3 2 2 2 1 2 3 3 3 2 1 3 1 3 2 3 1 3 2 3 3 1 2 1 2 2 3 1 3 2 2 1 1 2 3 1 1 3 1 3 2 2 3 2 2 1 3 2 2 2 3 3 2 3 1 2 2 1 1 1 2 3 2 1 3 2 1 1 1 3 3 1 3 1 3 2 2 1 1 1 1 2 1 2 3 1 2 1 2 2...
output:
1000 1 6 1501 2 15 1503 3 12 1502 0 4 1504 5 17 1498 7 21 1507 8 22 1508 9 25 1509 10 27 1510 13 36 1513 18 44 1517 19 49 1519 16 54 1520 20 40 1515 14 59 1523 23 38 1514 11 60 1525 24 28 1512 26 61 1526 29 63 1527 31 72 1530 33 82 1533 34 80 1532 37 87 1537 39 88 1538 43 101 1548 45 99 1546 46 102 ...
result:
ok count=1000
Test #133:
score: 0
Accepted
time: 0ms
memory: 16224kb
input:
3000 2 2 1 3 2 2 2 3 2 2 2 2 2 1 2 2 2 2 2 1 3 2 2 2 2 3 2 2 2 2 2 2 1 3 2 2 2 2 2 2 2 2 2 2 1 3 2 2 2 1 2 3 2 3 1 2 2 3 2 3 2 2 2 1 2 2 2 2 2 2 2 2 2 1 2 2 3 2 2 1 2 3 2 1 3 3 2 3 2 2 2 3 1 2 2 2 2 1 2 3 3 1 2 1 1 2 2 2 1 2 2 2 2 2 2 1 2 3 1 2 1 2 2 3 2 2 2 2 2 2 2 2 2 3 1 2 2 2 2 3 2 3 3 1 2 2 1 2...
output:
673 3 5 1538 2 4 1539 7 8 1537 19 22 1542 20 21 1541 25 26 1543 32 35 1545 33 34 1544 44 46 1546 45 47 1547 51 52 1549 49 50 1550 53 55 1548 54 56 1551 57 58 1552 59 60 1553 63 64 1554 76 77 1556 79 80 1558 81 82 1557 83 86 1559 84 88 1560 85 89 1561 87 90 1562 91 93 1563 92 94 1564 97 98 1565 99 10...
result:
ok count=673
Test #134:
score: 0
Accepted
time: 0ms
memory: 14116kb
input:
2999 2 2 3 3 2 1 2 1 1 2 2 3 2 3 2 3 2 2 2 1 2 3 2 2 2 2 1 3 2 3 3 2 1 2 3 2 2 2 2 1 2 2 2 2 2 3 2 2 3 1 2 2 2 3 2 2 2 3 3 2 2 2 3 3 3 2 1 1 2 2 2 1 2 2 1 1 2 2 2 2 2 1 2 2 2 3 2 2 3 3 3 1 1 2 2 3 2 2 2 1 2 2 2 2 2 2 2 2 1 2 2 2 1 2 3 3 1 1 2 2 2 2 1 1 2 2 3 2 3 2 3 2 2 2 3 2 2 2 1 2 1 3 2 3 2 2 2 1...
output:
683 5 9 1487 3 6 1488 7 10 1486 2 4 1489 8 12 1485 15 17 1493 19 20 1492 21 22 1494 26 28 1495 27 31 1496 30 35 1498 29 36 1499 32 33 1497 39 40 1501 45 46 1502 48 51 1504 49 50 1503 53 54 1505 62 65 1508 64 70 1511 66 69 1510 63 72 1512 67 68 1509 71 73 1513 74 76 1514 75 77 1515 81 82 1516 91 97 1...
result:
ok count=683
Test #135:
score: 0
Accepted
time: 2ms
memory: 14072kb
input:
2998 2 1 2 1 3 2 2 2 2 2 2 2 1 2 2 2 2 3 3 2 1 2 1 2 2 3 2 2 2 2 2 2 2 2 1 2 2 2 2 2 2 1 3 1 3 2 2 1 2 2 2 3 2 2 2 2 1 2 2 1 2 2 2 2 2 2 2 2 3 2 1 2 3 2 2 3 3 2 2 2 2 1 2 1 2 2 2 2 3 2 3 3 3 1 2 2 2 2 2 3 2 2 2 1 2 2 2 2 2 2 2 3 2 2 3 3 2 1 1 2 2 3 3 2 1 2 2 2 2 2 2 2 2 3 2 1 2 1 2 2 3 1 2 3 2 2 2 2...
output:
629 4 6 1541 17 19 1543 18 21 1544 20 23 1545 22 24 1546 25 26 1547 34 35 1548 41 45 1549 42 46 1550 43 48 1551 12 13 1552 44 49 1542 51 52 1554 56 57 1555 68 69 1557 70 71 1558 72 73 1559 59 60 1560 75 77 1556 47 50 1561 76 78 1553 88 89 1564 90 94 1565 91 95 1566 83 84 1567 92 96 1563 93 97 1568 8...
result:
ok count=629
Test #136:
score: 0
Accepted
time: 2ms
memory: 14140kb
input:
2997 1 1 3 2 3 3 2 2 1 2 2 2 2 2 2 1 3 3 2 2 2 3 2 2 2 2 3 2 1 3 2 3 2 3 2 3 3 2 2 2 2 2 2 2 1 1 2 2 3 3 2 1 2 2 3 3 2 2 1 1 1 2 1 2 1 2 2 1 2 1 3 1 3 3 1 2 2 2 2 2 2 1 2 2 2 3 2 2 3 2 2 1 2 2 3 2 1 2 2 2 3 2 2 1 3 1 2 2 2 1 3 2 2 1 2 3 2 3 1 3 2 2 3 2 2 2 2 1 2 2 2 1 1 2 3 2 2 2 3 2 3 1 2 2 3 2 2 2...
output:
712 0 3 1524 1 6 1525 4 9 1527 5 10 1528 2 7 1529 8 11 1526 15 18 1530 26 27 1535 28 30 1534 29 32 1536 31 34 1537 36 39 1541 44 46 1540 35 38 1542 45 47 1539 49 52 1544 48 50 1545 51 53 1543 55 57 1548 58 61 1547 59 63 1549 60 65 1550 62 66 1551 64 68 1552 67 75 1553 54 56 1554 69 76 1546 70 78 155...
result:
ok count=712
Test #137:
score: 0
Accepted
time: 2ms
memory: 9956kb
input:
3000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
1000 0 1000 2000 1 1001 2001 2 1002 2002 3 1003 2003 4 1004 2004 5 1005 2005 6 1006 2006 7 1007 2007 8 1008 2008 9 1009 2009 10 1010 2010 11 1011 2011 12 1012 2012 13 1013 2013 14 1014 2014 15 1015 2015 16 1016 2016 17 1017 2017 18 1018 2018 19 1019 2019 20 1020 2020 21 1021 2021 22 1022 2022 23 102...
result:
ok count=1000
Test #138:
score: 0
Accepted
time: 17ms
memory: 14580kb
input:
600000 1 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2...
output:
1 0 2 599999
result:
ok count=1
Test #139:
score: 0
Accepted
time: 58ms
memory: 20348kb
input:
600000 1 1 3 1 2 1 2 3 2 1 1 2 3 2 2 1 2 1 1 3 2 1 1 2 1 3 3 3 1 2 3 3 1 1 1 3 1 3 2 2 1 3 3 2 3 2 3 2 2 2 1 1 1 1 2 3 1 1 1 2 1 1 1 3 3 3 3 3 1 1 3 2 3 2 2 3 2 1 2 3 2 1 3 3 3 3 3 1 1 1 3 3 1 1 1 3 3 2 2 1 2 3 2 2 3 3 2 2 2 2 3 1 1 2 1 1 2 1 1 3 3 3 1 3 3 1 2 2 3 2 2 1 2 1 1 1 1 2 1 2 1 3 1 2 2 1 3...
output:
200000 1 6 299951 2 8 299953 3 11 299954 5 14 299956 7 13 299955 10 23 299962 12 20 299960 18 39 299966 17 43 299967 19 38 299965 22 47 299972 24 48 299973 21 49 299974 25 45 299971 26 54 299975 15 59 299976 27 29 299964 28 71 299977 30 73 299978 31 74 299979 32 76 299980 33 78 299981 34 97 299984 3...
result:
ok count=200000
Test #140:
score: 0
Accepted
time: 54ms
memory: 20336kb
input:
600000 3 1 2 3 3 2 1 1 1 2 3 2 2 3 3 3 2 2 2 2 2 3 1 3 3 1 2 1 3 1 3 1 2 3 3 3 1 1 2 1 2 1 1 3 1 3 1 2 1 1 3 2 2 2 3 2 2 2 1 1 1 3 2 1 1 1 2 3 1 2 1 1 2 3 3 3 2 3 2 2 2 1 1 2 3 1 2 1 3 2 2 3 1 1 3 1 2 2 2 1 3 3 3 1 1 2 1 1 3 3 3 2 2 3 1 2 2 1 3 1 1 2 3 3 3 3 3 1 1 3 3 3 2 1 1 3 3 2 2 2 3 2 2 3 1 1 3...
output:
200000 0 5 299982 1 2 299980 3 9 299984 4 11 299985 8 17 299989 10 18 299990 13 19 299991 14 20 299993 7 26 299995 15 16 299988 21 32 299996 22 38 299997 23 40 299998 24 47 300000 25 51 300001 27 53 300003 28 52 300002 29 55 300004 6 12 300005 30 56 299986 31 57 300007 34 66 300010 35 69 300011 33 7...
result:
ok count=200000
Test #141:
score: 0
Accepted
time: 12ms
memory: 23364kb
input:
210000 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 3 1 1 1 1 1 1 1 3 1 3 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
4999 6 240 204894 17 675 204905 25 894 204913 48 1760 204935 115 4438 205000 122 4682 205007 130 4947 205015 132 5027 205017 200 7518 205085 251 9625 205137 257 9727 205143 267 10117 205153 297 11456 205183 332 12955 205217 345 13427 205231 348 13478 205234 354 13836 205240 366 14243 205252 396 1539...
result:
ok count=4999
Test #142:
score: 0
Accepted
time: 3ms
memory: 12356kb
input:
15000 1 2 1 1 1 2 3 1 2 3 3 3 2 2 1 2 1 3 3 2 3 2 1 1 2 3 3 1 1 2 1 3 2 3 1 1 2 2 2 1 3 1 2 3 3 2 2 1 2 3 3 2 2 2 2 3 3 3 2 3 3 2 1 2 3 3 1 3 3 1 1 3 3 3 2 3 2 1 3 1 1 2 1 3 1 2 1 1 2 1 2 3 2 2 3 3 2 2 1 3 3 2 3 1 2 2 3 3 2 3 1 3 1 1 3 1 3 3 1 3 1 2 2 2 1 3 1 3 2 2 2 2 3 2 1 2 2 3 3 1 2 3 1 1 3 1 2 ...
output:
5000 0 1 7454 4 13 7461 6 12 7460 7 15 7465 9 19 7467 3 8 7468 10 21 7458 2 5 7469 11 24 7455 14 29 7470 16 32 7475 20 42 7484 22 38 7482 18 45 7485 23 37 7481 27 51 7490 28 52 7491 30 53 7492 31 54 7493 34 61 7498 33 63 7499 35 58 7497 39 74 7501 41 81 7503 44 88 7505 43 90 7506 47 85 7504 55 96 75...
result:
ok count=5000
Test #143:
score: 0
Accepted
time: 55ms
memory: 22760kb
input:
600000 3 2 1 3 1 1 2 3 1 1 2 1 2 2 1 1 2 1 1 2 2 2 1 2 3 3 2 2 1 2 3 1 2 1 2 2 3 2 2 1 3 1 2 2 3 1 2 1 2 3 1 2 1 1 2 3 2 2 2 1 2 3 3 1 2 1 3 2 3 1 3 2 1 2 3 2 1 1 3 1 2 3 2 1 2 3 1 3 2 1 1 1 2 2 1 1 1 2 1 3 2 2 2 3 2 2 2 3 1 2 1 3 2 3 3 2 3 1 1 3 3 3 1 1 3 1 1 1 1 1 2 1 3 2 2 3 1 2 1 1 1 2 2 1 2 2 2...
output:
200000 0 1 299818 2 6 299821 3 10 299828 5 13 299830 4 16 299831 7 12 299829 11 21 299834 14 23 299837 17 27 299840 22 32 299844 24 34 299845 18 35 299846 25 29 299842 28 37 299847 15 26 299852 30 38 299839 36 46 299856 40 51 299858 41 54 299859 44 56 299861 47 58 299863 45 60 299864 49 57 299862 50...
result:
ok count=200000
Test #144:
score: 0
Accepted
time: 57ms
memory: 20984kb
input:
600000 1 1 3 3 1 1 3 1 3 1 3 3 1 3 3 1 3 3 1 3 1 3 3 3 3 1 3 1 3 3 1 1 1 1 3 1 1 3 3 1 3 1 1 1 3 3 3 3 1 3 1 3 1 3 3 1 1 3 3 3 3 3 1 1 1 1 3 1 1 3 3 3 3 1 1 1 3 1 3 3 1 1 3 1 3 1 1 3 1 1 3 3 3 3 1 1 3 3 1 1 3 3 1 1 1 1 3 3 3 1 1 1 1 1 3 1 1 3 1 1 3 1 1 3 1 3 1 3 3 1 3 3 1 1 1 1 3 1 3 3 3 3 1 3 3 1 1...
output:
200000 1 2611 351502 0 3964 351503 2 947 351501 3 8354 351504 5 11205 351506 6 11334 351507 7 11342 351509 8 11341 351508 9 11343 351510 10 11344 351511 11 11345 351512 12 11347 351514 13 11346 351513 4 11348 351515 14 8355 351505 16 11350 351517 17 11351 351518 18 11352 351519 19 11353 351520 20 11...
result:
ok count=200000
Test #145:
score: 0
Accepted
time: 56ms
memory: 22548kb
input:
600000 3 1 3 3 3 1 1 1 1 3 3 1 3 1 3 1 1 3 3 3 1 3 3 3 3 3 3 3 3 3 3 3 1 3 3 3 1 1 3 3 3 1 1 1 3 3 1 1 3 3 1 1 3 1 1 1 1 1 3 3 1 1 1 3 1 3 3 3 1 1 3 3 1 3 1 1 3 3 1 3 1 3 3 3 1 1 3 3 3 1 1 1 3 3 1 1 1 3 3 1 1 3 1 3 1 1 3 3 1 1 1 3 1 1 1 3 1 1 3 3 3 3 1 1 1 1 1 3 3 1 3 3 1 1 1 1 1 3 1 3 3 1 1 3 1 3 1...
output:
200000 0 6995 338541 1 8232 338542 4 10456 338546 5 10446 338545 3 10458 338547 6 10408 338544 2 10459 338548 7 9381 338543 8 10460 338549 9 10461 338550 10 10462 338551 11 10464 338553 12 10463 338552 13 10465 338554 15 10467 338556 16 10468 338557 18 10470 338559 19 10471 338560 17 10472 338561 20...
result:
ok count=200000
Test #146:
score: 0
Accepted
time: 56ms
memory: 22992kb
input:
600000 1 3 3 3 1 3 1 3 1 1 3 1 3 1 3 3 3 1 1 1 3 1 1 1 3 1 3 3 3 1 3 3 3 3 3 3 1 1 1 3 3 3 1 1 3 3 3 3 3 1 3 3 3 3 1 3 3 3 3 1 1 1 1 1 3 3 3 3 1 1 1 3 3 1 1 1 3 1 1 1 1 3 3 3 3 3 1 3 3 3 1 3 1 3 3 1 1 3 3 3 1 1 3 1 3 3 1 1 1 3 3 1 1 1 1 3 1 3 1 1 1 3 1 3 3 3 1 3 3 1 1 3 1 1 3 3 1 1 1 3 3 1 1 3 1 3 3...
output:
200000 0 619 342941 1 1022 342942 4 1759 342945 5 2438 342946 3 2469 342947 6 1717 342944 8 2521 342949 7 2523 342950 9 2499 342948 10 2525 342951 11 2526 342952 13 2528 342954 16 2532 342958 17 2531 342957 15 2533 342959 18 2530 342956 19 2534 342960 20 2535 342961 21 2536 342962 14 2537 342963 22 ...
result:
ok count=200000
Test #147:
score: 0
Accepted
time: 7ms
memory: 12536kb
input:
60000 1 1 1 3 3 1 3 3 1 1 1 3 1 3 1 3 1 3 1 1 1 1 3 3 1 1 1 3 1 1 3 1 1 3 3 1 3 3 3 1 1 1 3 1 1 3 1 1 1 3 3 3 3 3 1 3 3 1 1 1 1 1 1 3 3 1 1 1 3 1 1 3 1 1 1 3 3 3 3 1 1 1 1 1 3 3 3 1 3 3 1 3 3 1 3 1 3 3 1 1 3 1 3 1 3 1 3 1 3 3 3 3 3 3 1 1 3 3 3 1 1 1 1 1 1 1 3 3 3 3 1 1 3 3 3 3 3 3 3 1 1 1 3 3 3 3 1 ...
output:
20000 0 167 27463 1 289 27464 2 348 27466 3 304 27465 4 391 27467 5 397 27468 7 423 27471 8 406 27470 9 428 27472 10 433 27473 11 435 27475 12 434 27474 13 437 27477 14 436 27476 15 438 27478 16 439 27479 17 441 27481 18 440 27480 6 442 27482 19 402 27469 21 445 27486 22 444 27485 23 446 27487 27 45...
result:
ok count=20000
Test #148:
score: 0
Accepted
time: 11ms
memory: 12432kb
input:
90000 3 1 1 3 3 1 3 3 3 3 3 3 1 1 3 3 1 1 1 3 3 1 3 1 1 1 3 3 3 3 3 1 1 1 1 1 1 1 3 3 3 1 1 3 3 3 1 1 1 3 3 1 3 1 1 1 3 1 1 3 3 3 1 1 1 1 3 3 3 3 1 1 1 1 1 1 1 3 3 3 3 3 3 1 1 1 3 1 1 3 3 1 1 3 3 1 1 3 3 1 1 3 3 1 1 1 1 3 1 3 3 1 3 1 1 3 1 3 3 1 3 3 3 1 3 1 3 1 3 1 3 1 3 1 3 3 3 1 1 3 3 3 3 1 3 3 1 ...
output:
30000 0 254 31570 2 283 31572 1 303 31573 3 282 31571 5 315 31575 6 319 31576 8 321 31578 9 322 31579 10 323 31580 11 324 31581 12 325 31582 13 326 31583 15 328 31585 14 329 31586 16 327 31584 7 330 31587 17 320 31577 4 331 31588 18 304 31574 19 332 31589 20 333 31590 21 334 31591 23 336 31593 22 33...
result:
ok count=30000
Test #149:
score: 0
Accepted
time: 7ms
memory: 18936kb
input:
120000 3 3 1 3 3 3 3 3 3 1 3 1 1 3 1 1 1 3 1 3 3 3 3 3 1 1 1 1 1 1 1 3 3 1 3 3 3 1 1 1 3 3 1 1 1 3 1 1 3 1 1 3 3 1 3 1 1 1 1 1 1 3 1 3 1 3 1 1 3 1 3 3 3 3 1 1 1 1 3 3 3 3 3 3 3 3 1 1 3 1 1 1 3 1 3 3 1 1 1 3 1 3 3 3 3 3 3 3 3 3 1 3 3 1 3 3 1 1 3 3 1 1 3 3 1 1 1 3 1 3 3 3 3 1 1 3 1 3 3 1 1 1 1 3 1 3 1...
output:
40000 0 556 62852 1 933 62854 2 819 62853 5 970 62857 7 993 62859 9 997 62861 10 999 62863 11 998 62862 12 1000 62864 13 1001 62865 8 1002 62866 14 995 62860 15 1003 62867 6 1004 62868 16 976 62858 17 1005 62869 18 1006 62870 19 1007 62871 20 1008 62872 21 1009 62873 22 1010 62874 23 1012 62876 24 1...
result:
ok count=40000
Test #150:
score: 0
Accepted
time: 13ms
memory: 19068kb
input:
150000 3 3 3 3 1 3 3 1 1 1 3 3 3 1 3 3 1 3 3 3 3 1 3 3 3 1 3 3 3 1 3 1 3 1 1 3 3 1 1 3 1 3 1 3 1 3 3 1 1 1 1 1 1 3 1 1 3 3 1 3 1 3 3 3 3 3 3 1 3 3 3 3 3 1 3 3 1 1 3 3 3 3 3 1 3 1 1 1 1 1 3 1 3 1 1 1 1 1 3 1 3 3 1 1 3 1 3 1 1 3 1 3 3 1 1 3 1 1 1 1 3 3 1 3 1 1 1 3 1 3 3 3 1 1 2 1 1 1 3 3 1 1 3 1 1 3 1...
output:
50000 3 4402 95283 2 4591 95284 4 3709 95282 6 4601 95286 5 4654 95287 7 4600 95285 1 4658 95288 8 1872 95281 9 4664 95289 11 4668 95291 12 4669 95292 10 4670 95293 13 4666 95290 16 4673 95296 17 4674 95297 18 4675 95298 19 4676 95299 20 4677 95300 15 4678 95301 21 4672 95295 22 4679 95302 24 4681 9...
result:
ok count=50000
Test #151:
score: 0
Accepted
time: 15ms
memory: 12640kb
input:
150000 1 1 1 1 3 1 3 3 1 1 1 1 1 1 3 3 1 3 1 1 1 3 1 3 3 3 3 3 3 3 1 3 1 3 1 1 1 3 1 1 3 3 3 3 3 1 1 1 1 3 3 1 3 1 1 3 3 1 1 1 3 3 1 3 3 3 3 1 3 3 1 1 3 3 1 1 3 1 3 3 1 1 1 3 3 1 3 1 1 1 3 3 3 1 1 1 1 3 3 1 3 3 3 3 1 1 1 3 1 1 1 3 1 1 1 1 1 3 1 3 1 1 1 3 3 1 3 3 1 3 3 1 3 3 3 3 1 3 3 3 3 1 3 3 3 3 1...
output:
50000 1 3463 66976 2 5543 66977 3 6350 66979 4 5668 66978 6 6437 66981 7 6446 66982 8 6449 66983 9 6450 66984 10 6451 66985 13 6455 66989 14 6454 66988 12 6456 66990 15 6453 66987 16 6457 66991 17 6458 66992 18 6459 66993 20 6461 66995 19 6462 66996 21 6460 66994 22 6463 66997 23 6464 66998 11 6465 ...
result:
ok count=50000
Test #152:
score: 0
Accepted
time: 12ms
memory: 14740kb
input:
150000 1 3 3 3 3 3 3 1 1 1 3 1 1 1 1 3 1 1 1 3 1 1 1 3 3 3 1 1 1 3 1 3 1 1 1 1 3 1 3 1 3 1 1 1 3 3 1 1 1 3 3 1 1 1 3 3 3 1 3 3 3 1 3 3 1 3 1 3 3 3 3 1 1 3 3 1 1 1 3 3 3 3 1 3 1 1 3 1 3 3 1 3 3 1 3 1 1 1 1 3 3 1 1 1 3 3 1 1 1 1 3 1 3 3 3 3 1 3 1 1 1 3 1 3 1 1 1 3 3 1 1 1 1 3 1 3 1 3 1 1 3 1 1 1 3 1 1...
output:
50000 1 1072 91547 0 1337 91548 2 995 91546 5 1402 91551 7 1404 91553 8 1405 91554 9 1406 91555 10 1408 91557 11 1407 91556 6 1409 91558 12 1403 91552 13 1410 91559 4 1411 91560 14 1392 91550 15 1412 91561 3 1413 91562 16 1349 91549 17 1414 91563 19 1416 91565 20 1417 91566 21 1418 91567 22 1419 915...
result:
ok count=50000
Test #153:
score: 0
Accepted
time: 48ms
memory: 25600kb
input:
600000 2 2 2 3 2 1 1 3 2 2 2 3 3 1 2 2 2 2 2 3 2 2 2 3 1 1 3 2 2 2 3 1 2 2 2 2 2 1 2 2 1 1 2 2 2 2 2 3 2 3 2 1 1 2 2 1 2 2 2 2 3 2 1 2 2 3 2 2 2 1 2 2 3 2 2 1 1 2 2 1 2 1 2 1 2 2 2 1 3 3 3 1 2 2 2 2 2 2 2 3 2 2 3 2 2 1 2 2 2 2 2 2 2 1 2 2 2 1 2 3 2 2 2 2 3 2 2 2 2 2 1 2 2 1 2 2 2 3 2 1 2 1 2 2 3 1 2...
output:
133513 3 4 300183 6 9 300185 7 10 300186 11 14 300187 5 8 300188 12 15 300184 13 16 300189 19 20 300190 23 27 300191 25 29 300193 24 32 300194 26 28 300192 30 33 300195 31 34 300196 37 38 300197 41 43 300199 40 42 300200 47 48 300198 49 50 300201 51 53 300202 55 56 300204 60 61 300205 62 63 300206 6...
result:
ok count=133513
Test #154:
score: 0
Accepted
time: 45ms
memory: 25728kb
input:
600000 2 2 2 2 3 1 2 3 2 2 2 1 1 2 2 2 2 2 2 2 2 1 3 2 3 1 3 2 2 2 2 2 2 1 2 2 2 2 2 2 2 2 2 2 2 3 1 2 1 2 2 2 3 2 2 2 1 1 3 2 3 3 3 3 2 2 2 2 2 2 2 2 2 3 2 2 2 2 2 1 3 3 2 2 3 2 2 3 2 2 3 2 2 2 2 2 3 2 2 2 1 1 2 2 2 2 3 2 1 2 1 2 2 2 1 2 2 2 2 1 2 2 2 1 1 2 2 2 2 2 1 2 2 2 2 1 1 3 2 2 2 2 2 3 2 3 3...
output:
133361 4 6 300070 5 8 300071 7 9 300072 11 13 300073 12 14 300074 22 27 300076 21 23 300077 24 28 300075 25 29 300078 33 34 300080 46 49 300082 48 50 300083 56 59 300085 57 64 300086 73 74 300093 79 82 300092 80 83 300094 81 85 300095 84 86 300096 87 88 300097 90 91 300098 96 97 300099 100 102 30010...
result:
ok count=133361
Test #155:
score: 0
Accepted
time: 47ms
memory: 23916kb
input:
600000 2 2 2 2 3 2 2 3 2 2 2 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 1 2 2 1 2 2 1 2 3 2 2 3 3 2 2 2 2 2 2 2 1 3 2 3 3 2 2 2 3 3 2 2 2 2 2 2 2 2 2 2 2 2 3 2 3 3 2 2 1 2 1 2 2 2 2 2 2 2 2 2 2 3 2 1 2 2 2 1 3 2 2 1 2 1 2 1 2 2 2 2 3 2 2 2 2 2 2 1 2 2 2 1 2 2 2 1 2 2 2 2 2 2 3 2 2 2 2 2 2 2 2 1 2 2 2 2 3 1 1...
output:
133217 7 8 300012 11 12 300013 27 29 300014 4 5 300015 28 30 300011 36 37 300018 39 41 300019 40 42 300020 48 50 300021 34 35 300022 49 53 300017 31 32 300023 51 54 300016 52 55 300024 56 58 300025 70 71 300027 72 74 300028 73 75 300030 76 77 300029 78 79 300031 89 90 300032 91 92 300033 57 59 30003...
result:
ok count=133217
Test #156:
score: 0
Accepted
time: 48ms
memory: 25532kb
input:
600000 2 2 2 2 2 2 3 3 2 2 3 3 3 1 2 2 1 2 2 2 2 2 2 2 2 2 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 1 1 2 2 2 2 2 2 2 2 2 2 2 1 2 3 2 2 2 2 3 1 3 2 3 2 1 1 2 2 2 1 2 2 2 2 2 3 2 2 2 2 1 2 2 2 2 3 2 1 2 2 3 2 3 2 2 2 2 3 2 3 2 2 2 2 2 2 1 3 2 2 2 2 1 2 2 2 3 1 3 2 2 1 1 2 1 2 2 2 1 1 2 3 1 3 3 2 2 1 2 3 1...
output:
133621 6 8 300263 7 9 300264 12 18 300268 13 17 300267 16 19 300269 26 28 300270 43 47 300273 44 46 300272 45 48 300274 57 58 300275 59 60 300276 65 69 300278 66 72 300279 70 74 300281 68 76 300282 71 73 300280 75 77 300283 81 82 300285 86 87 300284 93 94 300287 96 97 300288 98 99 300289 103 104 300...
result:
ok count=133621
Test #157:
score: 0
Accepted
time: 32ms
memory: 25472kb
input:
470000 2 2 1 3 2 1 1 2 3 3 2 2 2 2 3 2 2 3 2 2 2 2 3 2 2 2 2 2 2 2 2 2 2 2 2 3 2 2 3 2 2 2 2 2 2 2 2 3 2 2 2 2 3 2 2 2 1 2 3 2 3 3 3 2 3 2 2 2 2 3 1 2 3 2 1 1 2 2 2 2 2 2 3 3 2 1 2 1 2 2 2 3 2 2 2 2 3 2 2 3 2 2 2 2 2 2 2 1 2 2 2 2 2 2 2 2 2 2 2 3 3 3 2 2 3 1 3 2 2 2 2 2 1 3 2 2 1 2 2 2 2 2 2 2 2 1 3...
output:
104516 2 7 235051 3 4 235050 6 11 235053 5 12 235054 8 10 235052 9 13 235055 22 23 235058 52 53 235062 47 48 235063 56 57 235061 60 63 235065 69 73 235070 70 71 235069 72 77 235072 74 76 235071 64 67 235073 75 78 235068 83 86 235075 82 84 235076 85 88 235074 62 66 235077 87 89 235067 99 100 235080 9...
result:
ok count=104516
Test #158:
score: 0
Accepted
time: 31ms
memory: 27508kb
input:
470000 2 2 2 2 2 3 1 2 2 2 2 2 2 2 2 2 1 1 3 2 1 3 2 2 2 2 2 3 2 3 1 3 2 2 2 2 2 2 1 2 2 2 2 2 2 2 2 3 2 2 2 2 2 1 1 2 1 2 2 1 3 2 2 2 3 3 2 2 2 2 2 2 2 2 3 2 2 3 2 2 1 2 2 2 2 2 1 2 2 3 2 1 1 2 3 3 2 2 3 2 3 2 2 2 3 1 3 1 2 2 2 2 2 2 1 2 2 2 3 2 2 3 2 2 2 2 1 3 3 2 1 2 1 2 3 2 1 1 3 3 2 3 2 2 2 2 1...
output:
104147 5 7 234986 6 8 234987 16 19 234988 17 22 234989 18 23 234990 20 24 234991 21 25 234992 27 28 234993 29 33 234995 30 32 234994 31 34 234997 38 39 234996 53 55 234999 47 48 235000 54 57 234998 56 58 235001 59 61 235002 64 66 235004 74 75 235006 77 78 235008 80 81 235007 86 87 235009 89 90 23501...
result:
ok count=104147
Test #159:
score: 0
Accepted
time: 35ms
memory: 25528kb
input:
470000 2 2 2 1 1 3 2 1 2 2 2 2 1 3 2 3 3 2 2 2 2 2 2 2 3 2 2 2 2 3 3 2 2 3 3 3 2 1 2 2 2 2 2 2 1 3 2 2 1 3 1 1 1 2 2 2 2 2 2 1 2 3 2 2 1 2 2 2 2 2 2 3 1 3 3 3 2 1 2 2 3 2 2 1 1 2 1 3 3 2 2 2 2 2 2 1 2 3 2 1 3 1 2 2 2 2 2 2 3 2 3 2 1 3 2 3 2 3 3 1 2 2 2 2 1 1 2 3 2 2 3 2 2 2 1 2 2 3 2 2 2 2 2 1 1 2 2...
output:
104570 5 9 234845 12 17 234848 13 14 234847 15 18 234849 16 19 234850 7 10 234851 24 25 234846 4 8 234852 29 31 234844 30 32 234853 3 6 234854 33 36 234843 34 38 234855 35 39 234856 45 47 234859 48 53 234860 49 54 234861 50 55 234862 59 60 234865 52 57 234866 61 62 234864 64 65 234868 71 76 234867 7...
result:
ok count=104570
Test #160:
score: 0
Accepted
time: 38ms
memory: 27640kb
input:
469999 2 2 2 2 2 2 2 1 3 3 2 2 2 2 2 2 2 2 3 2 2 2 2 2 2 1 2 1 2 2 3 2 2 1 3 2 2 2 2 2 3 2 2 2 2 1 1 2 2 1 2 2 1 2 2 2 2 2 1 1 2 2 2 2 2 3 2 2 2 2 1 2 1 2 2 2 3 1 2 3 2 2 1 2 2 2 1 2 3 2 2 2 2 2 2 2 2 2 1 2 1 2 2 2 3 2 2 2 2 2 2 2 2 1 2 2 2 2 2 3 2 2 2 2 2 2 2 1 2 2 1 3 3 3 2 3 2 2 2 1 2 3 1 1 3 2 1...
output:
103891 7 10 234741 9 12 234743 18 19 234744 8 11 234745 25 26 234742 30 31 234747 33 35 234748 34 36 234749 40 41 234750 59 61 234756 65 66 234757 70 71 234758 72 73 234759 58 60 234760 76 78 234755 77 80 234761 79 81 234762 86 87 234764 82 83 234765 88 89 234763 98 99 234766 100 101 234768 104 105 ...
result:
ok count=103891
Test #161:
score: 0
Accepted
time: 11ms
memory: 20612kb
input:
600000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
1 0 120192 386125
result:
ok count=1
Test #162:
score: 0
Accepted
time: 6ms
memory: 10000kb
input:
149980 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2...
output:
1 77404 77405 91065
result:
ok count=1
Test #163:
score: 0
Accepted
time: 45ms
memory: 18320kb
input:
600000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
200000 0 200000 400000 1 200001 400001 2 200002 400002 3 200003 400003 4 200004 400004 5 200005 400005 6 200006 400006 7 200007 400007 8 200008 400008 9 200009 400009 10 200010 400010 11 200011 400011 12 200012 400012 13 200013 400013 14 200014 400014 15 200015 400015 16 200016 400016 17 200017 4000...
result:
ok count=200000
Test #164:
score: 0
Accepted
time: 16ms
memory: 14260kb
input:
600000 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2...
output:
1 0 1 599998
result:
ok count=1
Test #165:
score: 0
Accepted
time: 35ms
memory: 17844kb
input:
600000 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
120000 0 240000 360000 1 240001 360001 2 240002 360002 3 240003 360003 4 240004 360004 5 240005 360005 6 240006 360006 7 240007 360007 8 240008 360008 9 240009 360009 10 240010 360010 11 240011 360011 12 240012 360012 13 240013 360013 14 240014 360014 15 240015 360015 16 240016 360016 17 240017 3600...
result:
ok count=120000
Test #166:
score: 0
Accepted
time: 0ms
memory: 12176kb
input:
6 1 2 3 2 3 1
output:
2 0 1 4 2 3 5
result:
ok count=2
Test #167:
score: 0
Accepted
time: 50ms
memory: 18408kb
input:
599700 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...
output:
197700 0 197700 397600 1 197701 397601 2 197702 397602 3 197703 397603 4 197704 397604 5 197705 397605 6 197706 397606 7 197707 397607 8 197708 397608 9 197709 397609 10 197710 397610 11 197711 397611 12 197712 397612 13 197713 397613 14 197714 397614 15 197715 397615 16 197716 397616 17 197717 3976...
result:
ok count=197700