QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#725610 | #9571. Border Jump 2 | KJJD | AC ✓ | 691ms | 177892kb | C++20 | 9.6kb | 2024-11-08 19:04:18 | 2024-11-08 19:04:18 |
Judging History
answer
/*
注意到从前往后考虑 $ S $ 串不容易维护。我们考虑从最后一个状态出发,最后的 $ S $ 串一定存在是一个字符的情况。然后我们构成出反串 $ S^R $ ,上一个状态可能是由 $ t S w S ^ R t ^ R $ 组成,这里有两种情况。
1. 所有情况,那么贪心考虑, $t$ 和 $t^R$ 一定不存在。我们只需要寻找最靠前的 $S^R$ 即可,左边界不变($w$ 可能为空)。
2. 若 $ S $ 是回文串且 $ S $前面一个字符和后面一个字符相等,那么 $t S t$ 依旧是回文串,左边界左移1位。若$ t S $ 依旧是回文串,左边界左移1位。
注意到操作1的 $w$ 串为空时,新串为回文串,否则 $S$ 的长度至少翻倍。那么操作1在 $w$ 不为空的操作次数最多执行 $log$ 次。
注意到对于回文子串 $ T $ 可以写成 $ t w t^R $,在 $t$ 中选择的左端点进行操作1,一定能匹配到 $t^R$ 中的部分。若再执行操作2,一定劣于从 $w$ 开始执行操作2,且一定能执行出相同的左右端点。这里显然发现对于最多的操作次数一定为形如 $222...2111...1$ 。因为若操作1形成回文串,不如直接从回文中心开始构造。
再次注意到,对于回文串,考虑从回文串最左边开始匹配进行操作1,一定是匹配 $w$ 为空的新状态,即对于操作结束后相同的左端点可以执行操作2那么一定执行操作2。
那么我们用回文树/马拉车先维护出所有左端点开始操作最多的回文串。再暴力执行1操作,考虑次数即可。
这里提一下操作1的实现。可以用SA+二分找到$t^R$的$rk$范围。然后用主席树二分找大于这个位置的最小值。但是这个写法常数比较大,在cf被卡常了。我们可以用SAM或者exSAM,然后使用线段树合并,在线二维数点等方法找到大于这个位置的最小值。
时间复杂度O(nlognlogn)
*/
#pragma GCC optimize(2,"Ofast","inline")
#include <bits/stdc++.h>
#define ll long long
#define enl putchar('\n')
#define all(x) (x).begin(),(x).end()
#define debug(x) printf(" "#x":%d\n",x);
using namespace std;
const int MAXN = 2e5 + 5, LOG = 20;
const int inf = 0x3f3f3f3f;
const ll INF = 0x3f3f3f3f3f3f3f3f;
const int mod = 998244353;
typedef pair<int, int> pii;
char buf[1 << 21], * p1 = buf, * p2 = buf, obuf[1 << 21], * o = obuf, of[35];
#define gc()(p1==p2&&(p2=(p1=buf)+fread(buf,1,1<<21,stdin),p1==p2)?EOF:*p1++)
inline ll qpow(ll a, ll n) { ll res = 1; while (n) { if (n & 1)res = res * a % mod; n >>= 1; a = a * a % mod; }return res; }
template <class T = int>inline T read() { T s = 0, f = 1; char c = gc(); for (; !isdigit(c); c = gc())if (c == '-')f = -1; for (; isdigit(c); c = gc())s = s * 10 + c - '0'; return s * f; }
inline void read(int* a, int n) { for (int i = 1; i <= n; ++i)a[i] = read(); }
inline int inal(char* s) { int n = 0; for (s[0] = gc(); !isalpha(s[0]); s[0] = gc()); for (; isalpha(s[n]); s[++n] = gc()); return s[n] = 0, n; }
inline int indi(char* s) { int n = 0; for (s[0] = gc(); !isdigit(s[0]); s[0] = gc()); for (; isdigit(s[n]); s[++n] = gc()); return s[n] = 0, n; }
inline void outd(auto* a, int n) { for (int i = 1; i <= n; ++i)printf("%d ", a[i]); enl; }
int n, m, q;
char s[MAXN], str[MAXN];
int f[MAXN], com[MAXN];
struct SGT {
int L[MAXN * LOG * 8], R[MAXN * LOG * 8], v[MAXN * LOG * 8];
int T[MAXN << 1], tot;
void insert(int p, int& x, int l = 1, int r = n) {
if (!x)x = ++tot;
v[x]++;
if (l == r) return;
int mid = l + r >> 1;
if (p <= mid)insert(p, L[x], l, mid);
else insert(p, R[x], mid + 1, r);
}
void merge(int& x, int y, int l = 1, int r = n) {
// if (!x || !y) { x |= y; return; }
if (!y)return;
if (!x) { x = ++tot; v[x] = v[y]; L[x] = L[y], R[x] = R[y]; return; }
v[++tot] = v[y] + v[x];
L[tot] = L[x];
R[tot] = R[x];
x = tot;
if (l == r) return;
int mid = l + r >> 1;
merge(L[x], L[y], l, mid);
merge(R[x], R[y], mid + 1, r);
v[x] = v[L[x]] + v[R[x]];
}
int query(int x, const int& qv, int l = 1, int r = n) {
if (l == r)return l;
int m = (l + r) >> 1, res = 0;
if (qv <= m && v[L[x]])res = query(L[x], qv, l, m);
if (!res && v[R[x]])res = query(R[x], qv, m + 1, r);
return res;
}
};
struct exSAM : SGT { //最多2n-1个点和3n-4条边
int len[MAXN << 1], link[MAXN << 1], ch[MAXN << 1][26]; //我们记 longest(v) 为其中最长的一个字符串,记 len(v) 为它的长度。
int pos[MAXN << 1], rp[MAXN << 1];
vector<int> G[MAXN << 1];
int cur, lst, siz;
exSAM() { clear(); }
void clear() { //设置起始点S
for (int i = 0; i <= siz; ++i) G[i].clear();
memset(ch, 0, sizeof(int) * (siz + 1) * 26);
memset(pos, 0, sizeof(int) * (siz + 1));
memset(rp, 0, sizeof(int) * (siz + 1));
memset(T, 0, sizeof(int) * (siz + 1));
memset(L, 0, sizeof(int) * (tot + 1));
memset(R, 0, sizeof(int) * (tot + 1));
memset(v, 0, sizeof(int) * (tot + 1));
tot = 0;
len[0] = 0;
link[0] = -1;
siz = 0; //siz设置成0实际上有一个点,方便标记
lst = cur = 0;
}
int extend(int c) {
lst = cur;
if (ch[lst][c]) {
int q = ch[lst][c];
if (len[lst] + 1 == len[q])return cur = q;
else {
int clone = ++siz;
link[clone] = link[q];
len[clone] = len[lst] + 1;
link[q] = clone;
for (; ~lst && ch[lst][c] == q; lst = link[lst])ch[lst][c] = clone;
memcpy(ch[clone], ch[q], sizeof(ch[q]));
return cur = clone;
}
}
cur = ++siz;
len[cur] = len[lst] + 1;
for (; ~lst && !ch[lst][c]; lst = link[lst])ch[lst][c] = cur;
if (lst == -1) {
link[cur] = 0;
} else {
int q = ch[lst][c];
if (len[lst] + 1 == len[q]) {
link[cur] = q;
} else { //克隆的点是q(lst的c后继)
int clone = ++siz;
link[clone] = link[q];
len[clone] = len[lst] + 1;
link[cur] = link[q] = clone;
for (; ~lst && ch[lst][c] == q; lst = link[lst])ch[lst][c] = clone;
memcpy(ch[clone], ch[q], sizeof(ch[q]));
}
}
return cur;
}
int fa[MAXN << 1][LOG];
void dfs(int x) {
for (int i = 1; i < LOG; ++i)
fa[x][i] = fa[fa[x][i - 1]][i - 1];
if (pos[x])insert(pos[x], T[x]);
for (auto v : G[x]) {
dfs(v);
merge(T[x], T[v]);
}
}
void build() {
for (int i = 1; i <= siz; ++i) {
G[link[i]].push_back(i);
fa[i][0] = link[i];
}
dfs(0);
}
int FindR(int l, int r) {
int x = rp[l];
for (int i = LOG - 1; i >= 0; --i)
if (len[fa[x][i]] >= r - l + 1)
x = fa[x][i];
return x;
}
int find_nxt(int l, int r) {
if (r == n)return 0;
int x = FindR(l, r);
return query(T[x], r + r - l + 1);
}
}p;
void manacher(char* str, int n) {
int t = 0;
for (int i = 1; i <= n; ++i) {
if (t + f[t] >= i)f[i] = min(f[t - (i - t)], t + f[t] - i);
while (i - f[i] - 1 > 0 && i + f[i] + 1 <= n && str[i - f[i] - 1] == str[i + f[i] + 1])f[i]++;
if (f[i] + i > f[t] + t) t = i;
}
}
vector<array<int, 3>> op[MAXN];
void solve() {
p.clear();
n = inal(s + 1);
for (int i = 1; i <= n; ++i) {
int c = p.extend(s[i] - 'a');
p.pos[c] = i;
}
p.cur = 0;
for (int i = n; i >= 1; --i) {
int c = p.extend(s[i] - 'a');
p.rp[i] = c;
}
p.build();
// return;
int ans = 0;
for (int i = 1; i <= n; ++i) op[i].clear();
for (int i = n; i >= 1; --i)
com[i] = s[i] == s[i + 1] ? com[i + 1] + 1 : 0;
str[m = 1] = '#';
for (int i = 1; i <= n; ++i)
str[++m] = s[i], str[++m] = '#';
memset(f + 1, 0, sizeof(int) * m);
manacher(str, m);
// outd(f, m);
for (int i = 1; i <= m; ++i) {
int l = (i - f[i] + 1) / 2, c = (i + 1) / 2, r = (i + f[i]) / 2;
int f = i & 1 ? -1 : 1;
int v = min(c + com[c], r);
op[l].push_back({v, f * c, 1});
op[c].push_back({v, f * c, 0});
}
set<pii>S;
for (int i = 1; i <= n; ++i) {
for (auto x : op[i]) {
if (x[2])S.insert({x[0], x[1]});
else S.erase(S.find({x[0], x[1]}));
}
int v = 0, c = i;
if (S.size()) {
auto it = *S.rbegin();
v = it.first - i;
if (it.second > 0) c = it.second + it.second - i;
else c = -it.second - it.second - i - 1;
c = max(c, it.first);
}
while (c = p.find_nxt(i, c))
++v;
ans = max(ans, v);
}
printf("%d\n", ans);
}
signed main(signed argc, char const* argv[]) {
clock_t c1 = clock();
#ifdef LOCAL
freopen("in.in", "r", stdin);
freopen("out.out", "w", stdout);
#endif
//=============================================================
int TxT = 1;
TxT = read();
while (TxT--)
solve();
//=============================================================
#ifdef LOCAL
end :
cerr << "Time Used:" << clock() - c1 << "ms" << endl;
#endif
return 0;
}
这程序好像有点Bug,我给组数据试试?
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 0ms
memory: 36544kb
input:
3 aaaa abbaabba xy
output:
3 4 0
result:
ok 3 number(s): "3 4 0"
Test #2:
score: 0
Accepted
time: 0ms
memory: 38748kb
input:
15 eeee ooom bbcb yyaa ssdn wgww hrhr exer hcch qyyy lppa ocvo orxr lrjj pztv
output:
3 2 1 1 1 1 1 1 2 2 1 1 1 1 0
result:
ok 15 numbers
Test #3:
score: 0
Accepted
time: 3ms
memory: 34928kb
input:
52 eeeee oooom bbbcb yyyaa sssdn wwgww hhrhr eexer hhcch qqyyy llppa oocvo oorxr llrjj ppztv tnttt vnvvn hthhp jzjzj nrnrr gqgqt uruyu cdchd djdhh ktkfy piipp zaaza uffuq bvvvb hkkkk pcccj qccpq wqqaq appgg cxxvg ewfee peupe odfof kdpkh zotoz yzkzz irtrt vxyxi dlood akrrk nsbbb rdjjc bfexb uxsex ise...
output:
4 3 2 2 2 2 1 1 2 2 1 1 1 1 1 2 2 1 2 1 1 1 1 1 1 2 2 2 3 3 2 1 1 1 1 1 1 1 1 2 1 1 1 1 2 2 1 1 1 1 1 0
result:
ok 52 numbers
Test #4:
score: 0
Accepted
time: 4ms
memory: 38724kb
input:
203 eeeeee ooooom bbbbcb yyyyaa ssssdn wwwgww hhhrhr eeexer hhhcch qqqyyy lllppa ooocvo ooorxr lllrjj pppztv ttnttt vvnvvn hhthhp jjzjzj nnrnrr ggqgqt uuruyu ccdchd ddjdhh kktkfy ppiipp zzaaza uuffuq bbvvvb hhkkkk ppcccj qqccpq wwqqaq aappgg ccxxvg eewfee ppeupe oodfof kkdpkh zzotoz yyzkzz iirtrt vv...
output:
5 4 3 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 1 1 1 1 1 3 2 2 3 3 2 1 1 1 1 2 1 1 1 2 1 1 1 1 2 2 1 1 1 1 1 1 3 3 2 3 2 2 1 1 1 1 2 2 2 2 2 1 1 1 1 1 1 2 1 1 1 1 1 1 2 1 2 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 3 4 4 3 2 2 2 2 1 1 1 1 1 2 1 1 1 2 2 1 1 1 1 1 1 2 1 2 1 1 1 1 1 1 2 1 1 1 1 1 1 1 2 2 2 2 1 2 2 ...
result:
ok 203 numbers
Test #5:
score: 0
Accepted
time: 2ms
memory: 34972kb
input:
877 eeeeeee oooooom bbbbbcb yyyyyaa sssssdn wwwwgww hhhhrhr eeeexer hhhhcch qqqqyyy llllppa oooocvo oooorxr llllrjj ppppztv tttnttt vvvnvvn hhhthhp jjjzjzj nnnrnrr gggqgqt uuuruyu cccdchd dddjdhh kkktkfy pppiipp zzzaaza uuuffuq bbbvvvb hhhkkkk pppcccj qqqccpq wwwqqaq aaappgg cccxxvg eeewfee pppeupe ...
output:
6 5 4 4 4 3 3 3 3 3 3 3 3 3 3 3 2 2 2 2 2 2 2 2 2 3 2 2 3 3 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 3 2 3 2 2 2 2 2 2 3 2 2 2 2 1 1 1 1 1 2 2 1 1 1 1 1 1 2 1 2 1 1 1 1 1 1 3 3 3 2 2 2 2 2 2 2 4 3 3 4 4 3 2 2 2 2 2 1 1 1 1 2 1 1 1 2 2 1 1 1 1 1 1 2 2 2 2 1 1 1 1 1 2 1 1 1 1 1 1 1 3 2 2 2 1 2 2 ...
result:
ok 877 numbers
Test #6:
score: 0
Accepted
time: 12ms
memory: 34748kb
input:
4140 eeeeeeee ooooooom bbbbbbcb yyyyyyaa ssssssdn wwwwwgww hhhhhrhr eeeeexer hhhhhcch qqqqqyyy lllllppa ooooocvo ooooorxr lllllrjj pppppztv ttttnttt vvvvnvvn hhhhthhp jjjjzjzj nnnnrnrr ggggqgqt uuuuruyu ccccdchd ddddjdhh kkkktkfy ppppiipp zzzzaaza uuuuffuq bbbbvvvb hhhhkkkk ppppcccj qqqqccpq wwwwqqa...
output:
7 6 5 5 5 4 4 4 4 4 4 4 4 4 4 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 3 3 3 3 3 3 3 3 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 4 3 3 2 2 2 2 2 2 2 4 3 3 4 4 3 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 3 2 2 2 2 2 2 ...
result:
ok 4140 numbers
Test #7:
score: 0
Accepted
time: 53ms
memory: 35080kb
input:
21147 eeeeeeeee oooooooom bbbbbbbcb yyyyyyyaa sssssssdn wwwwwwgww hhhhhhrhr eeeeeexer hhhhhhcch qqqqqqyyy llllllppa oooooocvo oooooorxr llllllrjj ppppppztv tttttnttt vvvvvnvvn hhhhhthhp jjjjjzjzj nnnnnrnrr gggggqgqt uuuuuruyu cccccdchd dddddjdhh kkkkktkfy pppppiipp zzzzzaaza uuuuuffuq bbbbbvvvb hhhh...
output:
8 7 6 6 6 5 5 5 5 5 5 5 5 5 5 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 4 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 3 3 3 4 3 3 3 3 3 3 3 3 3 4 3 3 4 4 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 3 3 3 3 3 3 3 3 3 3 3 3 3 ...
result:
ok 21147 numbers
Test #8:
score: 0
Accepted
time: 144ms
memory: 141260kb
input:
2 eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee...
output:
99999 99999
result:
ok 2 number(s): "99999 99999"
Test #9:
score: 0
Accepted
time: 402ms
memory: 175140kb
input:
2 eeegeeeggegegeeeegegeeeeegeeegeeeggeeeggegggegeggeeeeegegeeggeeeggggeggggegegeegggegggggeggggeegggegeeegggeegeeegeeeegeggegeggeggeggegggeeeeggeggggggeggegggeegegegggeggegggeegeeggegeegegggeegegegggegggeeeggeggeeegeeggeeggeggegggeggeegegegeeggggegggggegegggeeeegegeeggeggegggegegeggeegggeeeggeeggegg...
output:
21 19
result:
ok 2 number(s): "21 19"
Test #10:
score: 0
Accepted
time: 391ms
memory: 161628kb
input:
2 egooeoegeeggegeeoegggoeoegeeeoeegoeeeogeoggoggoegoegogooooggoeeeoogooegeooegeeggeeoegeogoggegoegoggogeoogegggogegogeoogoeeeogegeoeoggoogoeeooeeogeoegggggegoeoeeggogogggeggoegeogoeogggegggeoggggooggoeoeeoegoeeggoogggggegooggoeooeoeeooeooggogeogeeoogegegoggeogeooeoggeogegoeogeeogeegogegoogggogegogeg...
output:
12 12
result:
ok 2 number(s): "12 12"
Test #11:
score: 0
Accepted
time: 362ms
memory: 154680kb
input:
2 oeoaooeggegegoeeeaeaoeoeogoeoaoeoaaeooaaogagogeaaoeoooaogooaaooogaaaoaagaeaegoeaaaoggaaaogggaeoaaaegeeeggaeoaoooaoeoeaeggoaogaeggoggeggaeoeogaeaggagaoggoaageeaoaeggaoggoagaeoaeeagoaoogogageoaeaoaggogggoeoagogaoooaeeagoeaaeaaoggaegaoegoaoaeoagageagaagoaegaaoeoeaoaeogaeagoggaoaoaeaaeogggeeegaooagega...
output:
11 9
result:
ok 2 number(s): "11 9"
Test #12:
score: 0
Accepted
time: 294ms
memory: 145464kb
input:
2 ntiaoioraegexnnnnxtxeetoogetixnoegbeitbgnrxbiatabitooeatbiibbinnxrrataxaanxnaetxrroraggriraggoobbxegootgrgterottateonbtgxnxnrgoaanrgnbagetioagnbgrarbexatbggenrtbearrnbgtxaatirtnagoaoibigxxiibtxorxanarrtitrbobxnttroixrenxgobrnbarnaanoxignrengrxroababxtbnbxxeinerobtibbibrngrrerebtabetxgbnioggteaxtra...
output:
5 5
result:
ok 2 number(s): "5 5"
Test #13:
score: 0
Accepted
time: 273ms
memory: 137256kb
input:
2 ojzxseudqfxhvuomjrexifhnelffzyfiprrzforwfkwqedndbhmhnogfcfirkfumbqlbjxlldhlnbizrrlnvcqagfbbdcthlgyjlhujxyytzdzzidtsnfqikankokdickzgvjgyajjmhwxfyaaydlmylhcaasplhgslxgelkidgljigipgbfrfhkigkxefcsgulblhdvbjpovwocxifzwpnwqtpkbslqndgxnwvfjverfyneyqaleydxbkovfgvgminukorptglmlrjqlaubjyedlmtkqvtopvwmfaahrk...
output:
3 3
result:
ok 2 number(s): "3 3"
Test #14:
score: 0
Accepted
time: 3ms
memory: 38736kb
input:
100 eeegeeeggegegeeeegegeeeeegeeeg eeeggeeeggegggegeggeeeeegegeeg geeeggggeggggegegeegggegggggeg gggeegggegeeegggeegeeegeeeegeg gegeggeggeggegggeeeeggegggggge ggegggeegegegggeggegggeegeegge geegegggeegegegggegggeeeggegge eegeeggeeggeggegggeggeegegegee ggggegggggegegggeeeegegeeggegg egggegegeggeeggge...
output:
7 5 6 5 6 6 4 6 6 4 6 10 7 5 10 6 10 8 5 10 7 10 7 6 11 10 8 7 5 5 7 8 5 6 6 10 5 7 8 8 8 6 7 6 9 6 6 6 4 5 5 4 6 8 8 6 6 6 4 9 11 7 5 12 8 8 9 7 5 6 10 6 6 7 7 9 5 7 11 6 8 8 5 5 10 6 9 6 9 8 5 5 6 6 6 8 6 7 9 6
result:
ok 100 numbers
Test #15:
score: 0
Accepted
time: 9ms
memory: 34656kb
input:
500 egooeoegeeggegeeoegggoeoegeeeo eegoeeeogeoggoggoegoegogoooogg oeeeoogooegeooegeeggeeoegeogog gegoegoggogeoogegggogegogeoogo eeeogegeoeoggoogoeeooeeogeoegg gggegoeoeeggogogggeggoegeogoeo gggegggeoggggooggoeoeeoegoeegg oogggggegooggoeooeoeeooeooggog eogeeoogegegoggeogeooeoggeogeg oeogeeogeegogegoo...
output:
2 7 4 5 5 3 4 4 3 3 5 5 4 5 4 4 4 4 5 3 5 7 3 3 3 3 8 3 4 6 4 5 4 3 3 6 3 3 4 2 3 5 3 5 4 4 3 4 3 4 4 4 5 4 4 5 4 3 4 4 3 4 5 5 4 4 4 5 4 4 3 3 3 4 3 5 4 6 6 6 3 6 4 5 3 4 3 4 4 3 4 4 3 3 4 4 4 3 4 4 4 5 6 3 3 4 3 5 4 5 4 3 3 5 7 5 7 4 3 2 3 7 4 4 6 5 5 4 5 4 6 2 2 5 6 6 7 3 2 4 4 4 5 5 6 4 3 3 3 4 ...
result:
ok 500 numbers
Test #16:
score: 0
Accepted
time: 175ms
memory: 109632kb
input:
2 babbababbabbababbababbabbababbabbababbababbabbababbababbabbababbabbababbababbabbababbabbababbababbabbababbababbabbababbabbababbababbabbababbababbabbababbabbababbababbabbababbabbababbababbabbababbababbabbababbabbababbababbabbababbabbababbababbabbababbababbabbababbabbababbababbabbababbababbabbababba...
output:
37511 37511
result:
ok 2 number(s): "37511 37511"
Test #17:
score: 0
Accepted
time: 0ms
memory: 36596kb
input:
1 abacbaxyabcaba
output:
2
result:
ok 1 number(s): "2"
Test #18:
score: 0
Accepted
time: 254ms
memory: 177892kb
input:
2 bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb...
output:
19102 17514
result:
ok 2 number(s): "19102 17514"
Test #19:
score: 0
Accepted
time: 239ms
memory: 146572kb
input:
2 ufgbkfjuuijotymncffyqnefotznsflvlihsxddzsjgkqvixsbtrbsbuooirmgytjbyfmlnqvnympwrrvkpacjouomhssrkcsdzbiijainkqfxyvleigspvnyweivxiaolxeatmaobcfczlicidyiozfhykxdvodanrcvlftjzxminuvvbmahwppjmxkmrfecmschtemfmedyduedbladcptkfjtovhcplarqdtcxhdlxpoqwmxfdveaksfvljgvimldtibzjccstyuwctjrptivddcphgmjjjeiuflqed...
output:
9999 9999
result:
ok 2 number(s): "9999 9999"
Test #20:
score: 0
Accepted
time: 255ms
memory: 137408kb
input:
2 eyqtmnrlcnohlapnzfpwmurpwngttugiqebhrvjsffsnribhchntexexcdlbwvtrdqyuajfrkegfixmewwqdhxpisibcnstuellgywtmngtaxhalgnjylglmdqxiaeqdhmalrvmljuqnrbuhwupcupsjdslnueybojeqhuxtfutscztokzwctikfalpkythkxyzxemizlewncihwjqhxxcxtuhnsebnenijhqrpjthyvqkqwkcqzgenfxeemsqlxnucfpzlbaemvhflhzgrpeckxfrrksbppiwsdghmbpl...
output:
4999 4999
result:
ok 2 number(s): "4999 4999"
Test #21:
score: 0
Accepted
time: 264ms
memory: 141584kb
input:
2 ivpnhczudisccdpuvnpthltbjnauoqjehspenapetoludiarsxftuwpzhvxofdzbmpzfdtuhavxcfdktfoceofowuhngrilioexzrydjrlbhzapcrhkbcbsjafaybzauyttajnsuiiaourefxcsrnafpvnidswelbanfhqtnffscraqfgnwmnbcarmkslrcmspvircgzjkztmztgmrqiopgbzxjhlrzrhqxrkyzclznfzqdqrzamvojicilyhyfqieoxygumfodmnyxkpzigpokngvqqtruhgzyngcuybf...
output:
5 5
result:
ok 2 number(s): "5 5"
Test #22:
score: 0
Accepted
time: 264ms
memory: 141868kb
input:
2 dcdyihlmsvlnewvitybmgqindedypovodrhvsomrhbtzokrvojunhvvegffukygrchxmzbuntugnunmloxiesdjbrqvfcitarlcdouhfktwpglyykuehlwxudcninuwzpaiahtbskewyozqwidlcprkrbpcdqqtluodfuttltpzxmmfcsihavyywecvugaojtvuqoadvsexnoohddzeyqbafvsxwfolxawigojpliretadebcgbwkrsjkzrqtzpdnsphmhdvreyslexnhhqkflumwnkhmfyufbpiokneiy...
output:
4 4
result:
ok 2 number(s): "4 4"
Test #23:
score: 0
Accepted
time: 274ms
memory: 150088kb
input:
2 hbbhbhhbbhhbhbbhbhhbhbbhhbbhbhhbbhhbhbbhhbbhbhhbhbbhbhhbbhhbhbbhbhhbhbbhhbbhbhhbhbbhbhhbbhhbhbbhhbbhbhhbbhhbhbbhbhhbhbbhhbbhbhhbbhhbhbbhhbbhbhhbhbbhbhhbbhhbhbbhhbbhbhhbbhhbhbbhbhhbhbbhhbbhbhhbhbbhbhhbbhhbhbbhbhhbhbbhhbbhbhhbbhhbhbbhhbbhbhhbhbbhbhhbbhhbhbbhbhhbhbbhhbbhbhhbhbbhbhhbbhhbhbbhhbbhbhhbbh...
output:
32768 32768
result:
ok 2 number(s): "32768 32768"
Test #24:
score: 0
Accepted
time: 225ms
memory: 129280kb
input:
2 abacabadabacabaeabacabadabacabafabacabadabacabaeabacabadabacabagabacabadabacabaeabacabadabacabafabacabadabacabaeabacabadabacabahabacabadabacabaeabacabadabacabafabacabadabacabaeabacabadabacabagabacabadabacabaeabacabadabacabafabacabadabacabaeabacabadabacabaiabacabadabacabaeabacabadabacabafabacabadab...
output:
34418 34456
result:
ok 2 number(s): "34418 34456"
Test #25:
score: 0
Accepted
time: 255ms
memory: 149484kb
input:
2 abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaababbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabba...
output:
32768 32768
result:
ok 2 number(s): "32768 32768"
Test #26:
score: 0
Accepted
time: 321ms
memory: 160248kb
input:
2 abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcacababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababca...
output:
2 2
result:
ok 2 number(s): "2 2"
Test #27:
score: 0
Accepted
time: 305ms
memory: 155236kb
input:
2 abcdbcdacdabdabcbcdacdabdabcabcdcdabdabcabcdbcdadabcabcdbcdacdabbcdacdabdabcabcdcdabdabcabcdbcdadabcabcdbcdacdababcdbcdacdabdabccdabdabcabcdbcdadabcabcdbcdacdababcdbcdacdabdabcbcdacdabdabcabcddabcabcdbcdacdababcdbcdacdabdabcbcdacdabdabcabcdcdabdabcabcdbcdabcdacdabdabcabcdcdabdabcabcdbcdadabcabcdbc...
output:
2 2
result:
ok 2 number(s): "2 2"
Test #28:
score: 0
Accepted
time: 292ms
memory: 149028kb
input:
2 abcdebcdeacdeabdeabceabcdbcdeacdeabdeabceabcdabcdecdeabdeabceabcdabcdebcdeadeabceabcdabcdebcdeacdeabeabcdabcdebcdeacdeabdeabcbcdeacdeabdeabceabcdabcdecdeabdeabceabcdabcdebcdeadeabceabcdabcdebcdeacdeabeabcdabcdebcdeacdeabdeabcabcdebcdeacdeabdeabceabcdcdeabdeabceabcdabcdebcdeadeabceabcdabcdebcdeacde...
output:
2 2
result:
ok 2 number(s): "2 2"
Test #29:
score: 0
Accepted
time: 256ms
memory: 134364kb
input:
2 foffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffofoffoffofoffoffofoffofoffoffofoffofoffoffofoffo...
output:
39304 39304
result:
ok 2 number(s): "39304 39304"
Test #30:
score: 0
Accepted
time: 248ms
memory: 132700kb
input:
2 jljpjljjljpjljljpjljjljpjljpjljjljpjljljpjljjljpjljjljpjljljpjljjljpjljpjljjljpjljljpjljjljpjljljpjljjljpjljpjljjljpjljljpjljjljpjljjljpjljljpjljjljpjljpjljjljpjljljpjljjljpjljpjljjljpjljljpjljjljpjljjljpjljljpjljjljpjljpjljjljpjljljpjljjljpjljljpjljjljpjljpjljjljpjljljpjljjljpjljjljpjljljpjljjljp...
output:
39325 39325
result:
ok 2 number(s): "39325 39325"
Test #31:
score: 0
Accepted
time: 355ms
memory: 159308kb
input:
2 wwwwwwwvfvfwfpfwwawwfawwfvfwwfwwwsffwwfwwffvwawfvwvwwvfppwffvpwwvwwvfwwwwffwfawvwwwwwvvffawfwpwwwvwwvfvwwwvpwwwfwfwwawvvawfwwwwvwwvffwwwsvfwwffwwwsffwvwwaavfwwfwffwfpwwwwwwwffwwwwwvvfwfvwwwfwwwwfwfwfawwwwfvwfffvawffwwaffaffffwwvefwaffvwwwwwwawwpwwvwwwvwfvufaawwfwwfwvwvwvvwwwwwfswwwfwfvfwwsfwwwfwwf...
output:
17 15
result:
ok 2 number(s): "17 15"
Test #32:
score: 0
Accepted
time: 442ms
memory: 166244kb
input:
2 cchcihcccccciccihhcciccfckiccccciccccccichcicccciciczcciciccciiciccfcchccchiccccccccicicccccicicccccickcccciihccciihciciiiiihicciichicciccccccicccihhcciccccklhccccccciccccccccccicciihcccccccccccccccciccciiccccccccchckhcchiiciccccccchcicccfcccccccihckchiccccicccfciiccccichccccchicchcccikccchiccccic...
output:
29 23
result:
ok 2 number(s): "29 23"
Test #33:
score: 0
Accepted
time: 363ms
memory: 159924kb
input:
2 lllalllllallllllllllllalalllllalllllalalblaalslallllllllallllalalllllllllbllllllalllallllllllsbblallalalalbaallallalaalbllbllllllllaallllllllbllllllsalllalbllllllllllbllalllllllalllaalalllllllllllllllllallalllllllalllallllllallblallllllllllalbabllballllllllaalllablllllalalllllallalblllallallllllll...
output:
42 36
result:
ok 2 number(s): "42 36"
Test #34:
score: 0
Accepted
time: 288ms
memory: 133672kb
input:
2 bbacaccabccacbabbbcbbcaabacaacbbaabacbaabccccbacaaccbacaabaacccacbcbccbabcbbbbbbcbaccabacabbcbcbbabbcaacbbbcbaccaccacaaaccbbcaccaaaaacaaabbacacbacccabbabbaabacacbaccabbbcccbbbccccccababbbacbcbcbbbcbcccccaabcccbcbaabcccbbbbbbacaccbccbccccbbccbaabcbbcbbbbccbbaacaaababccccacbbacbcccbbaaccccbcccabacca...
output:
12 10
result:
ok 2 number(s): "12 10"
Test #35:
score: 0
Accepted
time: 279ms
memory: 131896kb
input:
2 effaeacaeffeecdfafeacbbdfcdbeafbeceedbcbfdaafacfbebfdfbccdcadfcefceaafbffdcbccbfbcdbebfcbeaffcdaeabbfcdccaaadecccdccecdabeeecfeddecadafbdceafcfcbfeacbdcfcdaaddfaacffeacabaddbebdebbacedccbdccfbafacbbfaeedadeeecaffcefdccefeafdfdbcdbcaaaebbfceacfeedeecadefbfebdaddcbccbdcafaeecbbdbddcddabbbdaaefcdaccb...
output:
9 6
result:
ok 2 number(s): "9 6"
Test #36:
score: 0
Accepted
time: 285ms
memory: 131580kb
input:
2 gfbjegbhicjdedfiihggdcghdjgafafeggfeffajjhgfhjcchhbghiiejcbedhbgaajgbbiadiahcifhahbihcdiehdciihhecccifdcgbefcghfhfcedacfaafiaigibbfiagdbbeddidegbfagffjifjghjdgfehejbiagdabcihajbcgdebefbfcfddhgfibdfjahiagdahgdbjbijggeajigibbdajijbabhiihchhfcdagfiiggfegbagcdbfiibgijeedfebbeegidfhggeijhaagfjiehcaehed...
output:
6 5
result:
ok 2 number(s): "6 5"
Test #37:
score: 0
Accepted
time: 229ms
memory: 137320kb
input:
2 ababccabacccbccbacbabaacccacbaacbbbccbbbbcbcbbbacaccbcabaaccbbbbaaaabbabbbacaacacabcaabaacccccccacbcababcbacccbcbbbaaababbbcaccaaabccbaacababccabacccbccbacbabaacccacbaacbbbccbbbbcbcbbbacaccbcabaaccbbbbaaaabbabbbacaacacabcaabaacccccccacbcababcbacccbcbbbaaababbbcaccaaabccbaacababccabacccbccbacbabaac...
output:
8 10
result:
ok 2 number(s): "8 10"
Test #38:
score: 0
Accepted
time: 211ms
memory: 136408kb
input:
2 cafbedceafdfbcabaabbdeacfeecedefbedbddabdffececcaebcbcfaaadedadeedafafacaabdebcdbbbcebdfcebbcdacbacfcaedfcfedbcebebdcecfaccffbefefbcbacfacafbedceafdfbcabaabbdeacfeecedefbedbddabdffececcaebcbcfaaadedadeedafafacaabdebcdbbbcebdfcebbcdacbacfcaedfcfedbcebebdcecfaccffbefefbcbacfacafbedceafdfbcabaabbdeac...
output:
4 4
result:
ok 2 number(s): "4 4"
Test #39:
score: 0
Accepted
time: 201ms
memory: 134672kb
input:
2 ehdaahhcijcaajdgcaficajhfffaieibciddcccajbgefiaagghighhefebibjfedihcdcebfgchhddeddgbhgjihcieijiiibgjdaiaehejbcbchbdefjgdajadjefdgcaejbeedehdaahhcijcaajdgcaficajhfffaieibciddcccajbgefiaagghighhefebibjfedihcdcebfgchhddeddgbhgjihcieijiiibgjdaiaehejbcbchbdefjgdajadjefdgcaejbeedehdaahhcijcaajdgcaficajh...
output:
3 3
result:
ok 2 number(s): "3 3"
Test #40:
score: 0
Accepted
time: 206ms
memory: 140628kb
input:
2 bbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbbcbbbbaaabbacbbb...
output:
5 4
result:
ok 2 number(s): "5 4"
Test #41:
score: 0
Accepted
time: 160ms
memory: 136696kb
input:
2 haechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjcfehaechbdajjhjc...
output:
2 2
result:
ok 2 number(s): "2 2"
Test #42:
score: 0
Accepted
time: 214ms
memory: 136656kb
input:
2 gfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgfgqgfgpgfgqgfgrgfgqgfgtgfgqgfgrgf...
output:
49999 49999
result:
ok 2 number(s): "49999 49999"
Test #43:
score: 0
Accepted
time: 228ms
memory: 130516kb
input:
2 vgvjvgvpvgvjvgvavgvjvgvpvgvjvgvfvgvjvgvpvgvjvgvavgvjvgvpvgvjvgvzvgvjvgvpvgvjvgvavgvjvgvpvgvjvgvfvgvjvgvpvgvjvgvavgvjvgvpvgvjvgvnvgvjvgvpvgvjvgvavgvjvgvpvgvjvgvfvgvjvgvpvgvjvgvavgvjvgvpvgvjvgvzvgvjvgvpvgvjvgvavgvjvgvpvgvjvgvfvgvjvgvpvgvjvgvavgvjvgvpvgvjvgvmvgvjvgvpvgvjvgvavgvjvgvpvgvjvgvfvgvjvgvpvg...
output:
49151 49151
result:
ok 2 number(s): "49151 49151"
Test #44:
score: 0
Accepted
time: 248ms
memory: 133328kb
input:
2 lvlblvlqlvlblvlolvlblvlqlvlblvlelvlblvlqlvlblvlolvlblvlqlvlblvlalvlblvlqlvlblvlolvlblvlqlvlblvlelvlblvlqlvlblvlolvlblvlqlvlblvlrlvlblvlqlvlblvlolvlblvlqlvlblvlelvlblvlqlvlblvlolvlblvlqlvlblvlalvlblvlqlvlblvlolvlblvlqlvlblvlelvlblvlqlvlblvlolvlblvlqlvlblvlclvlblvlqlvlblvlolvlblvlqlvlblvlelvlblvlqlv...
output:
34464 34464
result:
ok 2 number(s): "34464 34464"
Test #45:
score: 0
Accepted
time: 237ms
memory: 137924kb
input:
2 cccdcccdcccdcccdcccfcccdcccdcccdcccdcccfcccdcccdcccdcccdcccfcccdcccdcccdcccdccccccdcccdcccdcccdcccfcccdcccdcccdcccdcccfcccdcccdcccdcccdcccfcccdcccdcccdcccdccccccdcccdcccdcccdcccfcccdcccdcccdcccdcccfcccdcccdcccdcccdcccfcccdcccdcccdcccdccccccdcccdcccdcccdcccfcccdcccdcccdcccdcccfcccdcccdcccdcccdcccfc...
output:
49995 49995
result:
ok 2 number(s): "49995 49995"
Test #46:
score: 0
Accepted
time: 398ms
memory: 161004kb
input:
2 vovvzvvovvzvvvzvvzzzvzvvzvvvzvvozvvzzvvvvovzvvvvvvzvvvvvvzzvvvovvvvvovvzzvvvzvvvvkovvvzzvvzvvvcvvzvvzvvvvvvvvvovzvvvvvzvvvzvvkvzzvzzvvvvvvvzvvvvovvzzvvvvvvzvovvvvvvzvvovvvvvvzzvzkovzkzzvvzvvvzvzvzvvzvvvvvovkvvvvzozvvzvvvvzzwvzvkzvzvvvzzvvvvvvvvvvovvvzkvzvvzvzvvvzvvzzvzvozzvwvvzzvvovvvvvvvzvvvvvovo...
output:
27 27
result:
ok 2 number(s): "27 27"
Test #47:
score: 0
Accepted
time: 366ms
memory: 164264kb
input:
2 nnnnngnqnnqnnnnnnnnqnnnnnngnggnngggnqgqgqnnnngnnngnqnnngqgynngwnnnnngggggnynggngnngnanqnnnnngnnnnngngnqnnnnngnnnqggnnnnnagnngnggqnnnnnnngnngnnnnnnnnnnnqnnnngnnnnannngngngnnqnnnnnnnnnwannnnnnngnnnnnngnqnngnnnnqnqnnnngnnngnnngnngnnnngngnnnggnznqnnngngngqnnnnnnngnqgagnnngnnnqnnnnnngnngqgnqgnnqngggnnn...
output:
23 25
result:
ok 2 number(s): "23 25"
Test #48:
score: 0
Accepted
time: 370ms
memory: 165924kb
input:
2 rrrrrrrrryfrfrrrrfrffrrryrrrfydryoyroyfrrrrrryrrdrryrryrfrrfrrffrfrrfrrffyrrrrrrrrrryrfrffrfrrfrrrrrrrfrrfrrrrrrrffrrrrrfrrrfrfroroyrfyrrrfrfrrrrrrfrfrfryffrrorrrrrfryrrrfyfrrryfrrfryrrryfrrrrffrrrfyrrffrrrrrrrrrrrdrrfyrrrrffffrrfyrrrrrryfrfrrrfrrrrryfryffrrrrrryfrrfrfrffrrdrfrffrrrorrfrrrorrfffrf...
output:
27 27
result:
ok 2 number(s): "27 27"
Test #49:
score: 0
Accepted
time: 152ms
memory: 140832kb
input:
100000 z e l n j i l j q f p j a c x s v u f c g t f n q r h y w m f q e m y k g e s s b r v g y v w z x t r n z y l w w x a g b a e h u v s y r x d t d p e s o w x q r p h v c i o i v w s a k q a z h l q x e n c n u i t d q v y n x r j u r s w x l p r z m c o e u i e y u i d c n o b i m m a m k k f...
output:
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok 100000 numbers
Test #50:
score: 0
Accepted
time: 185ms
memory: 136712kb
input:
6001 euaixlmvadbpevjhnlcsnhdgcemnmtyfilyxaybidwgiptoevvomzbsmtovcjxvspnzoqbcjqjgwckfy zm vlf ny koog dmsnhrdksmwos rdz ozqfyxvqz xxpbjlrmrijtkttngozukt dgksww ibwyrsfjvkyhvqyhowmblilzqloryhvy kglvivbokvkzktpofu kquuufonscc ubnlwlrzkgxs pknkgtkipoabs o eu wenaarskkhiutwtvoeddbcucnqxojfykakqgeivybxmib...
output:
1 0 0 0 1 1 0 1 1 1 1 1 2 1 1 0 0 1 1 1 1 0 0 1 0 1 1 1 1 0 1 1 1 1 1 1 2 0 0 2 1 0 1 1 1 1 1 1 2 1 1 1 1 0 1 0 0 1 2 1 0 1 1 0 1 1 1 2 0 1 1 1 1 1 1 1 1 0 2 1 1 0 1 1 1 1 1 1 0 1 1 1 0 0 1 1 0 1 1 1 0 1 1 1 1 1 1 0 0 0 1 1 1 1 1 0 1 0 1 1 0 1 1 0 1 0 1 1 1 0 1 1 1 0 1 0 1 0 0 1 0 1 1 1 1 1 1 1 1 1 ...
result:
ok 6001 numbers
Test #51:
score: 0
Accepted
time: 179ms
memory: 136996kb
input:
301 oxodofzcvwlpqdmqacwookn hbzxcbarhkzvsxpuojpowprdybaogiubumdapxmrguptwhfwredcnuxggsucefgslpfwmjvatolqafqnmthjswgqowmiiivezwfphcvwxldypzucwfvpwlhfrqymjvymudkezwapwsrfdvitkqsvfvgxzazbxhbpgtmtthmgisopuenfcafqjjdbyvmeqcxgqljthjzfctlpytqnytiihuhkelrjwqqpczbmzgnnxbykzyahkrlvyibulosxdjsehcmveixnzruirrqd...
output:
1 2 1 3 2 2 1 1 1 2 1 1 2 2 3 2 3 2 2 2 2 2 2 3 1 3 2 2 1 2 1 2 1 2 1 2 2 2 1 2 2 2 2 2 1 2 2 2 3 2 2 1 1 2 1 2 2 1 2 1 2 2 2 2 2 2 2 2 1 0 2 3 1 2 2 2 2 2 1 1 2 2 3 1 1 1 2 1 2 1 4 3 2 2 1 1 2 2 2 2 0 2 2 2 2 2 2 1 2 2 2 2 2 2 2 3 3 2 2 2 1 2 2 3 2 2 2 2 2 2 2 4 2 3 2 2 2 2 2 2 2 1 1 2 2 1 2 2 1 2 ...
result:
ok 301 numbers
Test #52:
score: 0
Accepted
time: 555ms
memory: 156804kb
input:
2 tliyfmwnwnxwvzwriubuspwqczypwmujdfoqrushlhgvqnqanqzydlbiwlryoahrouacuswtwivqxxqdynebljjahlmwbvhwatwxtpofpgllbntszjxmwleixjbyzbbnixxzwbsdcyzxmvneoqiquvsqvyjyhhbmpcclhlftfdtrefcjtlfhmuocurwosqtplcxsinrvaxbrahteypivdwtwmufmmedzsnaalzdgnkhffbnooephryrqtnxgqzjnzywlawyapnperyoxjkiglffgcuswrsbjbwyecnwnye...
output:
19 50
result:
ok 2 number(s): "19 50"
Test #53:
score: 0
Accepted
time: 536ms
memory: 160260kb
input:
2 qtvyigvzjcibaqvdooncntfixbwgibzrbkjpwfrzwhaqkmcqzixpdojdxhklnyzaehzwubqcfdgikjhosobectzngttityjreekbpuynsjzgsspjnntwbnnwliaqgxpzmhskhauxakxavkrtqpbodcoxznprrqquuwwnfobgyyqqsntwjuobuyltijusfzwyythcqtljpfmbzhxreotaqurewlqxocyzrrsyiikvlvumurddzouxgraycoyafvfuklugnbtcqnbbkwfptxphlfgsvlurcqzexbacsynugo...
output:
24944 53
result:
ok 2 number(s): "24944 53"
Test #54:
score: 0
Accepted
time: 613ms
memory: 163844kb
input:
2 dyqrxwqoqvqzcnxrhiuyypiczmkwrkiggayvhczajbxzkqxcuamrkigvspsymszexpnviwpxtabkwmizpudqwesoyzikbaizbfrcwpsthhsijtukirpjmsjdrivpiwblqlvwkbbayrlzucmljtewlhjlwadnjlbsepgjzkjpgoaasbcndmtoqxvyaswexkhnujyexbyhfinqkmkeqltrtabfnrtjpzcckvcqmxcowaqfxadoxloaycpqnfxjogjfdxibiiwewtnomyooqygeyaprrokeeqnqmjokejaqnz...
output:
7051 16
result:
ok 2 number(s): "7051 16"
Test #55:
score: 0
Accepted
time: 575ms
memory: 163916kb
input:
2 smuwxdlpllsfmtobjosrbngipyarpjujtxrskuovthdfkdcosrwplanerzpkzsmcdnrjiihytkidevgiacknjpkilvwxktimrwasnkaedpfzxcjxfqdjskonrllvnhacmaghosadfodginjodbvhntnbqrvnujdiiptlznuzgnovnyqdupuabhvwbtxlxzqkpeyoopmlvgfytvxtzfdcofazcixxddbrlvvceyyvqqzixlrzcnhyinqtpjcctyheoepusonwmyggbmybeoiduzpetqonbhrxgwjdcdywmn...
output:
21 47
result:
ok 2 number(s): "21 47"
Test #56:
score: 0
Accepted
time: 577ms
memory: 157460kb
input:
2 snfkjadzedhysnhkiymwvhgzvsnrtfobnuwtrmnfphipliqgkqgjsvnczddszeifzufsoysyrnxkatwtebckgzirjpnmbpnqadnoliqrwxgxvmxcebtamtziqdvnkgvejzjcmahmqfglzpvlouwxukmphkijecqfdatfrdtkgeubqjnvsgegyakdwppdpmrlzqkompyisxslixzdvwfyhdvexskkwgvqneawscbofumifhmdymfmaxkvhflgwwjdnwfbwikyvbgvpglbsgzbhysbhqbtfwyxftpqqhdgub...
output:
49 38
result:
ok 2 number(s): "49 38"
Test #57:
score: 0
Accepted
time: 488ms
memory: 153020kb
input:
2 htjsygicjcwqhpmbwcllabxhbpzvnsbjxkhlyszdhpfsxarslhmefwreazhfofpdbjtiohiasafybpozkxzzxfdpqsbwrcwbzbbrbdbzswaiviutcdvzxuphuyjojjdwyjslkaifucgruaiywvkwhgsupyzhynsejdllxkknbifesyriilmizxhaywkukglludidlpojglnlrxptartamyqokbjzgtzhxiktaagfnjlghmofoklpoutfuisyvvfcjxliwqpuaangkipezvethmvojrrojfvgzanughhqvn...
output:
26444 49
result:
ok 2 number(s): "26444 49"
Test #58:
score: 0
Accepted
time: 520ms
memory: 159000kb
input:
2 oujbuxdmxulyepaticecfzcqteeauquvpabvhiqhyfunlyjklujrksneaxtecjibnxvypynlbdumrzvgcffvggvrsfbkmirigbykpgnfslbmrrunuaesyzgdblbxeqsamshslyrtagbddbddeaxlpmiqnevnfijlaagyksnmmxjbmssduvajzkhyrrpgrworidhtlkjnvhqvzhphuxnquabymheneukwsullmhyoxqovittinrbibtoekiwrfksupvrcxcpdmctcdudzmwpuleluvdnxzrsgarvsicszvq...
output:
51 33749
result:
ok 2 number(s): "51 33749"
Test #59:
score: 0
Accepted
time: 622ms
memory: 159156kb
input:
2 rknhypvpgxzggcixotxntyzjfmjvwgpefckhzlmnoykvlanmmibvikmfabevnfajyqudxycahutfvaskzevlksfvpydbfpvwxjrulzncfxjvqxsukwqgwbcwfuzbeqqnsbuxqymaejlrnnnjeggsocmybputwrzaneoigkkpxvpfdwibqkwhueghghklstqllrjtiybrdotceryggihpbiwazxwllezbslzrwbbssobvbzrvsqhfzpmgqcmghdwwrmhrycedmchnxeledmgshqhlsekiktomkyuirujeic...
output:
16 2276
result:
ok 2 number(s): "16 2276"
Test #60:
score: 0
Accepted
time: 236ms
memory: 137700kb
input:
2 vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv...
output:
11626 12595
result:
ok 2 number(s): "11626 12595"
Test #61:
score: 0
Accepted
time: 222ms
memory: 140296kb
input:
2 vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv...
output:
17270 12438
result:
ok 2 number(s): "17270 12438"
Test #62:
score: 0
Accepted
time: 430ms
memory: 147148kb
input:
2 pyigpguhsdafmsufbsuosigtjkomaunwlbsgpbtosmbmvbezecxoeknqgthmqvwogftsgnjbeezbfzdilerxhxclrhgmybfvaswrshhmjdjwhjoqjvdidafmkyxcfvbxsurmhesqyccyhbaengjcymgnvxszrwmksesiamybvkgrpczdikveuqkyeppzhzknqpugcoaicxpoqntzfzqocqqjrdkaebkvdhofhtbqvkbztqufvcfpldcbfvgtyhxvcljmeriymdvqgfublnpldxxupgvnbdpvuywujwkulc...
output:
29 17
result:
ok 2 number(s): "29 17"
Test #63:
score: 0
Accepted
time: 459ms
memory: 149172kb
input:
2 tztgugjmxgxzgxzdwsjhckljncqzgvcvcayfqxmibxvtssmmbvwjnnafuckosccexlprgiahnywcvbwdgmatdytpizqsojgsxeqdjzijnocjghttzpbnkdkkvduybiauioqdnirmxhscdubwlofizkjhnxijwlbqqnhbhnprfgsgjpaaoqooldnnsfugmspmmqdrkuhguawqzdqbhqtzxwocejvutfkttzqdmqhkoocyagmewiyqfbtdjlibhhtaqywjhizyhtmdrlaydhitxrzqqbnxhdravkmcxqtmuu...
output:
28 18
result:
ok 2 number(s): "28 18"
Test #64:
score: 0
Accepted
time: 518ms
memory: 147720kb
input:
2 jgvxdrmxawlmijubmrhrztyvnblfmrzbsluqhwnclaejnbytpphhirnechzsncxuyeczbunlnzqvcflabiveztzygrlagubwxpagyeztigejcseyxajlxbmypnakhvmnijtalmxawzurlwzaelpzpdyajshanfrecnwzhvdylkznhzerbbekronotqjuuwplioidzgkarympwnipjgbhnzktutlmqbzllvgraiaditvruqphyvhgydhmcpasxuwtthqhfeaatqpqctesyvmcjfyflaqrhkaduoztygjipj...
output:
19 15
result:
ok 2 number(s): "19 15"
Test #65:
score: 0
Accepted
time: 483ms
memory: 148512kb
input:
2 klssqcrjefikabhfhrlfjpdamsajxwzrzicmrqqimpeyzbpuyvptdferycgazgbvkjivipohpkuxbrmvugxhionqzdrkftedewxcfmoqyeywehjakzfarrfkmcjprpbzvhnxbcntgblwmassxkojvuizizozyjwjvwhgezftyxwunxtkuafpkmpzhlsvhedwxiozawkhlkhqzizjnutobzaeikhfuejdcpuyhouszgegiywegkhcekoglyvpcwbtqvknhevnnghngrdqnfdlrnbnngwyncwsbvcxbueyka...
output:
26 20
result:
ok 2 number(s): "26 20"
Test #66:
score: 0
Accepted
time: 256ms
memory: 146940kb
input:
2 hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh...
output:
3583 4600
result:
ok 2 number(s): "3583 4600"
Test #67:
score: 0
Accepted
time: 251ms
memory: 146492kb
input:
2 mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm...
output:
8186 3383
result:
ok 2 number(s): "8186 3383"
Test #68:
score: 0
Accepted
time: 432ms
memory: 154984kb
input:
2 kiedsgdswrdfwyzyxasfzdmgcyepwzptnidkvmkgferpmkrwrclndrgdghcqqgvysjfyapcweqzrrovgcslkhyuzxaqjkzaybdicrbxiagjnqhcjjnrnjyqpcscfqgvvjxzqkcfqxevgsmuhlobnoagqoksgtnmlnpbnvpfpxsyholknyrkxgigjclqriobmphnzavxoddbgzldcmrurgajwopjzimqnbnognlizjrkpxvvzbmccexwysxjgrgieuuqukwsnxkzhywkjfyfnbbzbukdbbjlowciquprhqi...
output:
28 18
result:
ok 2 number(s): "28 18"
Test #69:
score: 0
Accepted
time: 407ms
memory: 145988kb
input:
2 mmpiwcoleevlwjvnhsabdqacdhjinjtmdtpwuxilpevwqagtjkmbzikbxvxvwspynkcqbbepkqwtlxxvjacigfhjsbpmhlfuulqwuhiljievgwabxbofktccoecpgxeyczprabcqplajlwztdccdfzdhivemvqmcytizziyvofzmxrrbmzajutdmbhloaomkmbvortxjkhsvvwaxftnwtwjzpstmzphrmpgaorskgdxuzassjtepmknmmifehlbwvdqjyugqcscpiphypbzrdwpxzdwjiqswcjjnltawoo...
output:
28 18
result:
ok 2 number(s): "28 18"
Test #70:
score: 0
Accepted
time: 373ms
memory: 145416kb
input:
2 xncrwqwwemxswhlbqkgbfwckgkizefjkldyscppufedcnqrqsbyrkrxlkrisxnyehetqpqsaeephozvqotlusaztpacecgytzkwhgumjcqxhgffdgqbnrwcfakmqingfqrytkvkwsvqbenxszmnqtigqpbidxgujrycceprtxfeyxiyopwnvnshlhhwgnrtbgafwyparpgughchdjyhcuyopnrrenjbirxjsuxeqdpcufutlwutlqzjsdgiweahslmnmjmrjctryvqzocwycarzcqvudienpocslqpnrrc...
output:
21 21
result:
ok 2 number(s): "21 21"
Test #71:
score: 0
Accepted
time: 381ms
memory: 145040kb
input:
2 dfkxktlhjhowekakwykibxsvodiuduwfonsaloaxriusxjxpaozqeinfswvbxjmeoypnaiuwaijahtsxdtkooecxpobfqfhuuuygwsxhvlgbsqbcqeruuqfeughuoecfvvhhtbalcszaludrqtusrlgztlyvgwezijyvqnlfhbeoggvxwbqbnkpyalxtehgkvzwkeyfjvdbvazbvixzvjlmklqrehrwzfgwiojjyrsktvrwrgfzryrtmaxnedtitejugrtbbziwnnbxbviytmpmlazulqrsrekpalbyfdt...
output:
17 29
result:
ok 2 number(s): "17 29"
Test #72:
score: 0
Accepted
time: 170ms
memory: 143920kb
input:
2 xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx...
output:
33309 33300
result:
ok 2 number(s): "33309 33300"
Test #73:
score: 0
Accepted
time: 166ms
memory: 142236kb
input:
2 jjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj...
output:
33318 33304
result:
ok 2 number(s): "33318 33304"
Test #74:
score: 0
Accepted
time: 210ms
memory: 127900kb
input:
2 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
output:
8093 8061
result:
ok 2 number(s): "8093 8061"
Test #75:
score: 0
Accepted
time: 212ms
memory: 136136kb
input:
2 ddddddddddddddddddddhhhhhhhhhhhhhhhhhhhhbbbbbbbbbbbbbbbbbbbbllllllllllllllllllllrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmjjjjjjjjjjjjjjjjjjjjppppppppppppppppppppzzzzzzzzzzzzzzzzzzzzttttttttttttttttttttyyyyyyyyyyyyyyyyyyyyiiiiiiiiiiiiiiiiiiiinnnnnnnnnnnnnnnnnnnnkkkkkkkkkkkkkkkkkkkkwwwwwwwwwwwwwwwwww...
output:
20 20
result:
ok 2 number(s): "20 20"
Test #76:
score: 0
Accepted
time: 217ms
memory: 135756kb
input:
2 yyyyyyyyyyyyyyyyyyymmmmmmmmmmmmmmmmmmmiiiiiiiiiiiiiiiiiiinnnnnnnnnnnnnnnnnnnkkkkkkkkkkkkkkkkkkkvvvvvvvvvvvvvvvvvvvhhhhhhhhhhhhhhhhhhhjjjjjjjjjjjjjjjjjjjllllllllllllllllllloooooooooooooooooooqqqqqqqqqqqqqqqqqqqgggggggggggggggggggdddddddddddddddddddfffffffffffffffffffbbbbbbbbbbbbbbbbbbbeeeeeeeeeeeee...
output:
19 19
result:
ok 2 number(s): "19 19"
Test #77:
score: 0
Accepted
time: 222ms
memory: 130784kb
input:
2 uuuuuuuuuuuuuuuuuuvvvvvvvvvvvvvvvvvvbbbbbbbbbbbbbbbbbbyyyyyyyyyyyyyyyyyyeeeeeeeeeeeeeeeeeeppppppppppppppppppkkkkkkkkkkkkkkkkkkhhhhhhhhhhhhhhhhhhssssssssssssssssssmmmmmmmmmmmmmmmmmmwwwwwwwwwwwwwwwwwwddddddddddddddddddcccccccccccccccccciiiiiiiiiiiiiiiiiiaaaaaaaaaaaaaaaaaarrrrrrrrrrrrrrrrrrjjjjjjjjjj...
output:
18 18
result:
ok 2 number(s): "18 18"
Test #78:
score: 0
Accepted
time: 230ms
memory: 138980kb
input:
2 tttttttttttttttttwwwwwwwwwwwwwwwwwjjjjjjjjjjjjjjjjjqqqqqqqqqqqqqqqqqgggggggggggggggggpppppppppppppppppbbbbbbbbbbbbbbbbbssssssssssssssssslllllllllllllllllxxxxxxxxxxxxxxxxxzzzzzzzzzzzzzzzzzvvvvvvvvvvvvvvvvvdddddddddddddddddaaaaaaaaaaaaaaaaayyyyyyyyyyyyyyyyyuuuuuuuuuuuuuuuuucccccccccccccccccrrrrrrrrr...
output:
17 17
result:
ok 2 number(s): "17 17"
Test #79:
score: 0
Accepted
time: 209ms
memory: 135128kb
input:
2 ssssssssssssssssggggggggggggggggzzzzzzzzzzzzzzzzttttttttttttttttddddddddddddddddqqqqqqqqqqqqqqqqwwwwwwwwwwwwwwwwiiiiiiiiiiiiiiiiaaaaaaaaaaaaaaaacccccccccccccccchhhhhhhhhhhhhhhhjjjjjjjjjjjjjjjjyyyyyyyyyyyyyyyyxxxxxxxxxxxxxxxxrrrrrrrrrrrrrrrruuuuuuuuuuuuuuuuppppppppppppppppffffffffffffffffbbbbbbbbbb...
output:
16 16
result:
ok 2 number(s): "16 16"
Test #80:
score: 0
Accepted
time: 222ms
memory: 133152kb
input:
2 bbbbbbbbbbbbbbbrrrrrrrrrrrrrrrwwwwwwwwwwwwwwwlllllllllllllllooooooooooooooodddddddddddddddmmmmmmmmmmmmmmmiiiiiiiiiiiiiiikkkkkkkkkkkkkkkyyyyyyyyyyyyyyyzzzzzzzzzzzzzzznnnnnnnnnnnnnnnjjjjjjjjjjjjjjjfffffffffffffffpppppppppppppppgggggggggggggggeeeeeeeeeeeeeeecccccccccccccccxxxxxxxxxxxxxxxttttttttttttt...
output:
15 15
result:
ok 2 number(s): "15 15"
Test #81:
score: 0
Accepted
time: 221ms
memory: 137004kb
input:
2 ddddddddddddddvvvvvvvvvvvvvvssssssssssssssmmmmmmmmmmmmmmooooooooooooooppppppppppppppffffffffffffffiiiiiiiiiiiiiiqqqqqqqqqqqqqqzzzzzzzzzzzzzzxxxxxxxxxxxxxxjjjjjjjjjjjjjjcccccccccccccckkkkkkkkkkkkkkbbbbbbbbbbbbbbnnnnnnnnnnnnnnrrrrrrrrrrrrrrwwwwwwwwwwwwwwllllllllllllllhhhhhhhhhhhhhhttttttttttttttgggg...
output:
14 14
result:
ok 2 number(s): "14 14"
Test #82:
score: 0
Accepted
time: 691ms
memory: 138216kb
input:
2 bcdbefbdcbghbcdbfebdcbijbcdbefbdcbhgbcdbfebdcbklbcdbefbdcbghbcdbfebdcbjibcdbefbdcbhgbcdbfebdcbmnbcdbefbdcbghbcdbfebdcbijbcdbefbdcbhgbcdbfebdcblkbcdbefbdcbghbcdbfebdcbjibcdbefbdcbhgbcdbfebdcbopbcdbefbdcbghbcdbfebdcbijbcdbefbdcbhgbcdbfebdcbklbcdbefbdcbghbcdbfebdcbjibcdbefbdcbhgbcdbfebdcbnmbcdbefbdcb...
output:
15 15
result:
ok 2 number(s): "15 15"
Test #83:
score: 0
Accepted
time: 630ms
memory: 148952kb
input:
2 bcdbefbdcbghbcdbfebdcbijbcdbefbdcbhgbcdbfebdcbklbcdbefbdcbghbcdbfebdcbjibcdbefbdcbhgbcdbfebdcbmnbcdbefbdcbghbcdbfebdcbijbcdbefbdcbhgbcdbfebdcblkbcdbefbdcbghbcdbfebdcbjibcdbefbdcbhgbcdbfebdcbopbcdbefbdcbghbcdbfebdcbijbcdbefbdcbhgbcdbfebdcbklbcdbefbdcbghbcdbfebdcbjibcdbefbdcbhgbcdbfebdcbnmbcdbefbdcb...
output:
15 15
result:
ok 2 number(s): "15 15"
Test #84:
score: 0
Accepted
time: 196ms
memory: 132308kb
input:
2 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
output:
19101 19348
result:
ok 2 number(s): "19101 19348"
Test #85:
score: 0
Accepted
time: 191ms
memory: 131456kb
input:
2 aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
output:
19367 19187
result:
ok 2 number(s): "19367 19187"
Test #86:
score: 0
Accepted
time: 188ms
memory: 160620kb
input:
2 abcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabca...
output:
2 2
result:
ok 2 number(s): "2 2"
Test #87:
score: 0
Accepted
time: 163ms
memory: 162708kb
input:
2 abcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabcabca...
output:
2 2
result:
ok 2 number(s): "2 2"
Extra Test:
score: 0
Extra Test Passed