QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#572657 | #5084. Longest Substring | daxinghao# | AC ✓ | 110ms | 34280kb | C++14 | 4.0kb | 2024-09-18 15:50:50 | 2024-09-18 15:50:50 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
#ifndef LOCAL
#pragma GCC optimize("O3")
#pragma GCC target("avx2")
#else
#endif
#define int long long
#define sz(v) ((int)(v).size())
#define MAX(x, y) (x = max((x), (y)))
#define MIN(x, y) (x = min((x), (y)))
#define pi array<int, 2>
#define all(v) (v).begin(), (v).end()
vector<int> Suffix_array(string s){
int n = (int)s.size(), m = max(300ll, n + 1);
vector<int> sa(n), gr(n * 2), ngr(n * 2), cnt(m), imsi(m);
for(int i = 0; i < n; ++i) sa[i] = i, gr[i] = s[i];
for(int len = 1; len < n; len <<= 1){
for(int i = 0; i < m; ++i) cnt[i] = 0;
for(int i = 0; i < n; ++i) ++cnt[gr[i + len]];
for(int i = 1; i < m; ++i) cnt[i] += cnt[i - 1];
for(int i = n - 1; i >= 0; --i) imsi[--cnt[gr[i + len]]] = i;
for(int i = 0; i < m; ++i) cnt[i] = 0;
for(int i = 0; i < n; ++i) ++cnt[gr[i]];
for(int i = 1; i < m; ++i) cnt[i] += cnt[i - 1];
for(int i = n - 1; i >= 0; --i) sa[--cnt[gr[imsi[i]]]] = imsi[i];
ngr[sa[0]] = 1;
for(int i = 1; i < n; ++i) ngr[sa[i]] = ngr[sa[i - 1]] + (gr[sa[i - 1]] < gr[sa[i]] || (gr[sa[i - 1]] == gr[sa[i]] && gr[sa[i - 1] + len] < gr[sa[i] + len]));
swap(gr, ngr);
if(gr[sa[n - 1]] == n) break;
}
return sa;
}
vector<int> Lcp(string s, vector<int> sa){
int n = (int)s.size(); s += '^';
vector<int> lcp(n - 1), rk(n);
for(int i = 0; i < n; ++i) rk[sa[i]] = i;
for(int i = 0, j = 0; i < n; ++i) if(rk[i]){
while(s[i + j] == s[sa[rk[i] - 1] + j]) ++j;
lcp[rk[i] - 1] = (j ? j-- : 0);
}
return lcp;
}
signed main(){
ios_base::sync_with_stdio(false);
cin.tie(0);
string s; cin >> s;
int n = sz(s);
auto sa = Suffix_array(s);
auto lcp = Lcp(s, sa);
vector<pi> ans(n + 1);
vector<vector<pi>> spa(n - 1, vector<pi>(18));
for(int i = 0; i < n - 1; ++i){
spa[i][0] = {lcp[i], i};
}
for(int j = 1; j < 18; ++j){
for(int i = 0; i < n - 1; ++i){
spa[i][j] = spa[i][j - 1];
if(i + (1 << j - 1) < n - 1){
MIN(spa[i][j], spa[i + (1 << j - 1)][j - 1]);
}
}
}
auto sol = [&](auto&&self, int s, int e, int ed)->set<int>{
assert(s <= e);
if(s == e){
if(ed < n - sa[s]){
pi val = {1, n - sa[s]};
if(val > ans[1]) ans[1] = val;
}
set<int> st;
st.insert(sa[s]);
return st;
}
pi mn = {(int)1e9, (int)1e9};
for(int j = 17; j >= 0; --j){
if(s + (1 << j) > e) continue;
MIN(mn, spa[s][j]);
MIN(mn, spa[e - (1 << j)][j]);
break;
}
assert(mn[1] < (int)1e9);
int p = mn[1], tlen = mn[0];
auto st = self(self, s, p, tlen);
auto st2 = self(self, p + 1, e, tlen);
if(sz(st2) > sz(st)) swap(st, st2);
for(auto&v:st2) st.insert(v);
auto getcnt = [&](int gap){
int rv = 1;
int now = *st.begin();
while(true){
auto nxt = st.lower_bound(now + gap);
if(nxt == st.end()) break;
++rv;
now = *nxt;
}
return rv;
};
if(ed < tlen){
int sval = getcnt(ed + 1);
int low = ed + 1, high = tlen, mid;
while(low < high){
mid = low + high + 1 >> 1;
if(getcnt(mid) == sval){
low = mid;
}
else{
high = mid - 1;
}
}
pi val = {sval, low};
if(val > ans[e - s + 1]) ans[e - s + 1] = val;
}
return st;
};
sol(sol, 0, n - 1, 0);
for(int i = 1; i <= n; ++i){
cout << ans[i][1] << ' ';
}
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 0ms
memory: 3596kb
input:
ababa
output:
5 2 1 0 0
result:
ok single line: '5 2 1 0 0 '
Test #2:
score: 0
Accepted
time: 0ms
memory: 3884kb
input:
aaaaaaaa
output:
8 7 6 5 4 3 2 1
result:
ok single line: '8 7 6 5 4 3 2 1 '
Test #3:
score: 0
Accepted
time: 0ms
memory: 3588kb
input:
a
output:
1
result:
ok single line: '1 '
Test #4:
score: 0
Accepted
time: 0ms
memory: 3824kb
input:
abcdefghijklmnopqrstuvwxyz
output:
26 0 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 single line: '26 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #5:
score: 0
Accepted
time: 86ms
memory: 34280kb
input:
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...
output:
50000 49999 49998 49997 49996 49995 49994 49993 49992 49991 49990 49989 49988 49987 49986 49985 49984 49983 49982 49981 49980 49979 49978 49977 49976 49975 49974 49973 49972 49971 49970 49969 49968 49967 49966 49965 49964 49963 49962 49961 49960 49959 49958 49957 49956 49955 49954 49953 49952 49951 ...
result:
ok single line: '50000 49999 49998 49997 49996 ... 13 12 11 10 9 8 7 6 5 4 3 2 1 '
Test #6:
score: 0
Accepted
time: 99ms
memory: 29796kb
input:
abababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababab...
output:
50000 49998 49996 49994 49992 49990 49988 49986 49984 49982 49980 49978 49976 49974 49972 49970 49968 49966 49964 49962 49960 49958 49956 49954 49952 49950 49948 49946 49944 49942 49940 49938 49936 49934 49932 49930 49928 49926 49924 49922 49920 49918 49916 49914 49912 49910 49908 49906 49904 49902 ...
result:
ok single line: '50000 49998 49996 49994 49992 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #7:
score: 0
Accepted
time: 20ms
memory: 15448kb
input:
hnpyezhavuychdbjldxjofydbuekupcjllbrtehyfangipyjjqhivkyhnlrotjgftqhwlpvmsjtikgsspaxswleauvtzbmqjdywpnilqhawmcqprtynqylzbjganroyiwcbiyqklolxabdowwkrxhzuahgjabvvrkdelzvtdsavbipxpddsopnnxjwasoxnpgknyxrcuypmbgvgymrlymkcufnptcdwbpihxhayfqoylfvrgzhhferphxfjruejyztauvklpchuxduvosjrbwqvnofdnzhtkvwwbdenlzkyf...
output:
30918 6 4 3 3 3 3 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 0 0 0 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 0 2 2 0 2 2 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok single line: '30918 6 4 3 3 3 3 3 0 0 0 0 0 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #8:
score: 0
Accepted
time: 26ms
memory: 17892kb
input:
ujwgcpuvylongozaczorldxrlmgmdyxenplvanjgtgfgzdvllphwyuqvjmzvfskbmjndeazlljvcjwpgmbmhhnlppoahzjxzhlastuawhchrbajvfxgpxgrrzjjnufizgrofjnegdgrdsxnepoajtppsqpsjvscmekdwbsfecczcittiirastwwmhzrtjwksdlwchghosqslgniyxkvoukvbqhmfegaxrljefutidcelusbenpvuzwizoiznksyejikaovbngxmzzjrrumgdkvczjftegspfutgyayaxfozq...
output:
36879 5 4 3 3 3 3 3 3 0 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 0 2 0 0 2 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok single line: '36879 5 4 3 3 3 3 3 3 0 3 0 0 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #9:
score: 0
Accepted
time: 26ms
memory: 16284kb
input:
jrjefrpmcidljqjqbgcezgstiefshrvwcmtciarsnrnuucovzlltwvbmorxkwlrquidxnvejjedkendyssdtulgavoninkvcjzcpxsnnofaprgfclhxuezkbsezoefqgnnyxbvutgazsjttfftpjturngqoxpisvkpvkgypdpdwittmxnaaorxdkrldlrtatxwheabbyrezemqvymwzqffpysmqicopqxmsydemwzzalmjmjaewqqxwribmpfkafjmgsrpeimoulryfmmrxbvrhxatwoqrtaxqgboohpyqoe...
output:
32956 6 4 3 3 3 3 3 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 0 2 0 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok single line: '32956 6 4 3 3 3 3 3 3 0 0 0 0 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #10:
score: 0
Accepted
time: 27ms
memory: 18488kb
input:
bqxywpdcsnccafvrbhsoffpezhdlywtbqpnqfkibmmvsacuohwzsrfmbvqhnqhhnvbkpzrofxssllygtwhxmbtxhvrnivshojgahurbgsnyvxgfdyzgqldgrbnutsakmruxlaadlqqiucwoumrhbkwdosgujwarnmgsjmsexfchydumtjapmngxzyxomsqqfxiksydtjvjnlimzjjeewbjmawzoqmkloamspatyraxnjdkncradykxajsqdbsbairguqqsaixggzrpavkporwnlbukavfsnzqsrxrjokttkn...
output:
37924 6 4 3 3 3 3 3 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 2 0 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 0 2 2 2 0 2 2 0 2 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok single line: '37924 6 4 3 3 3 3 3 3 0 0 0 0 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #11:
score: 0
Accepted
time: 14ms
memory: 11648kb
input:
bpgokflgellqalcfmnkaazoyenqztpllksopthmvpkmdgmjuhsdmawvgnxomrjpolstdymwkkjpxwxqeltezasdzatufflpyqrgtrkccierbjnrlguvpvyfrgvguivfdpcoankfoooewwulzzmbnltuysvvbethgnvdwpeusklobltcwvubybjtknhzpappqihgnziujksebunfncqgbqylpszscsvhuwmextkqlbxjktubotyzmhklohbesxujsduwreuayrhbsmsbimdlnzxllygzazsavtdejpdkhonch...
output:
21337 6 4 3 3 3 3 3 0 0 0 0 0 0 2 2 0 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok single line: '21337 6 4 3 3 3 3 3 0 0 0 0 0 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #12:
score: 0
Accepted
time: 75ms
memory: 24376kb
input:
baaaabbababbabbaabbbabaabbababbbbababaaaabbbabaabaabaababbabaabbabaaaababbbbbaaabaaabbabaaabbbabbaababbbbabbbbabbabbbaabbaababbaabbabababbbbbbbabbaaaababbababbbbabbbaabbabbabaabaaaaaaababaaaaabbbbbabbaaaaabbabbbaabbbaabbabababbbaabbaaabaaaabaabaabaabaabbbbbbaabaabbaaaaaabababaabaabbaaaaababbbbbbbbba...
output:
50000 30 22 19 18 17 16 15 14 14 14 14 13 13 13 13 13 12 12 12 12 12 12 12 12 11 11 11 11 11 11 11 11 11 11 11 11 11 11 10 11 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 0 9 9 0 9 9 9 9 9 0 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 ...
result:
ok single line: '50000 30 22 19 18 17 16 15 14 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #13:
score: 0
Accepted
time: 68ms
memory: 24560kb
input:
aaabbabbabaaabbaaabaaaababbaaaaaabbbabbabbbbbaababbbabbaaaaaabaaabbabbbabbaabbbabbbbaabababbbabbbabbbabaababbaaaabaaabbbaaabbbbaaabaaaabaabaaabbaabababaabaaabbabbabbababbbbbababbaaaaabababbaaababbbaabbabbaabbbaaabbbaabbabbbaaabbaabbbbbaaaabbaabbbaabbbaaaababbbbaabaabbabbabbabbbabbaaabbbabababbbababa...
output:
50000 28 24 20 19 17 16 16 15 14 14 13 13 13 13 13 13 13 12 12 12 12 12 12 12 12 11 11 11 11 11 11 11 11 11 11 11 11 11 10 10 10 11 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 0 9 0 9 9 10 0 9 0 9 9 0 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 ...
result:
ok single line: '50000 28 24 20 19 17 16 16 15 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #14:
score: 0
Accepted
time: 80ms
memory: 24392kb
input:
bbbbbbbabaaaaabaaaaabaaabaabaaabbbabbbbabaabaabaaaabbbabbbbbabbbaabababbabbbabaaabbbabbbababbabaabaaabbbabbbabaabbabbababbbbbbaaabbbbbbabbbbaabaaaaabbbabbbbbabbabaaaaaaaabaaabbbbbababbaaabaabbabaaabbbabaabaaaaaabababbabbbabbaabaaaaabaabbaabaabaabaabbbbabbababbbaaabbaaaaabaababbbaabbaaabbabaaaaabaabb...
output:
50000 33 20 18 17 16 16 15 14 14 14 14 13 13 13 13 12 12 12 12 12 12 12 12 12 12 11 11 11 11 11 11 11 11 11 11 11 11 11 11 10 10 11 11 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 9 10 9 0 9 0 10 9 0 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9...
result:
ok single line: '50000 33 20 18 17 16 16 15 14 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #15:
score: 0
Accepted
time: 71ms
memory: 24332kb
input:
abaaabbbbaabaaabbabbbbabababbaabbabbbabbbabbaabbbbabbbbbaabbabaaabaabaababbaaaaabbbbababbaaabaaaaabbaabbaaababababbbaabaaabbaaaabbbababaabbaababbbaaabbbbbbabaababbbbabbbbbabbaabbbbaaabaaabaabbaaaabaaaabbababbbababbaaabbabbbbababbbbaabbbbbaaabaabababbbaaaabbbabbabbabababbabaabaabbaabababbaabababbbaba...
output:
50000 28 21 19 18 17 16 15 15 14 14 14 14 13 13 13 13 13 12 13 12 12 12 12 12 12 11 12 11 12 11 11 11 11 11 11 11 11 11 11 11 11 10 10 10 10 10 10 11 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 0 10 10 0 10 10 9 9 0 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 ...
result:
ok single line: '50000 28 21 19 18 17 16 15 15 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #16:
score: 0
Accepted
time: 80ms
memory: 24428kb
input:
baabababbbbbbabbbbbbbbbbabaabbbaaaabaaabbabaabbaaababaabbbaabababababbbaababbaabbabbbababbabbaabababbaabaaaaaaaabbabaabbbbabababbbaaaaaabbaabbbabbabbabbaabbabbababaaabaaaaabaabbabaababbbabbabaaaaaaaaabbbaaabbaaabbbbaabbbaabbaaaaaaababaaabbbbaabbbabbaabbbbaaaabbababaaaababbabaaaabbaabababaaaababbbaba...
output:
50000 29 22 18 17 16 15 15 14 14 14 13 13 13 13 13 12 12 12 12 12 12 12 12 12 11 11 11 11 11 11 11 11 11 11 11 11 11 11 11 11 10 11 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 9 10 9 0 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 ...
result:
ok single line: '50000 29 22 18 17 16 15 15 14 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #17:
score: 0
Accepted
time: 64ms
memory: 23824kb
input:
wvwwwuuvwwwuuwvwuwwwuvuuuvwuwuwuwuvuuvwvvvuuvuwuvvuvvuuuwuvvwwvwwvwvvwwvvuvwuuvuuuwuuwvvuuuwvuwwwvwvvuuuwuuuwvwuuwuwwvvwvwvwvwwvwvuvuwvvwuuwvwvvvwvwwuwwvvvvvuwuuwwwuwuuvvvvuwwuuuwuwwuvvvvwwvuwvwuvuuuvuwvuwuvvwwwuuwwvwwuwvvuvuuvwuwvuuuwuuwuuvuwuuwuvuuwuwvuvwuvwwvwuuuvuuwvuwuuuwwuuuuuvvvvuvwwwwvuvuuwv...
output:
50000 23 14 12 11 10 10 9 9 9 9 8 8 8 8 8 8 8 8 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 0 0 0 6 0 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 0 6 6 0 0 0 6 0 0 0 6 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 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 single line: '50000 23 14 12 11 10 10 9 9 9 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #18:
score: 0
Accepted
time: 69ms
memory: 23984kb
input:
qrqqqqqrrrrrrpprqprrpqprprrppqpqqrpprqrrppqqqrqpqpqprrprqpqprqqqqqrrrrpqrpqqqrppppqqrrrqpqprprqqqpqqqqprpprqqqppqpppprppqpppppprqqprrqrprrqqpqrqrqprqpprpqqppprqqpprqrqprqrqqrqqqrprqpqpqpprpqqqqpqqqqqpqqqppqqqqqrqprqprrprprprprpppqqqqpqppqqqprqrqqrqrqrrrpprrrrrqrprrpqpqrrrrrqrqpppqrprppqqrrpqqqrprrrp...
output:
50000 18 13 12 11 10 9 9 9 9 9 8 9 8 8 8 8 8 7 8 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 0 0 0 0 6 0 0 0 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 0 6 6 0 0 6 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 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 single line: '50000 18 13 12 11 10 9 9 9 9 9... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #19:
score: 0
Accepted
time: 68ms
memory: 23824kb
input:
opoqoqpqopqpqppqoooqoqpqpooppqppqooqoqpooqpqopqpoqqqqqqqqqpqoqqoooqpqpoqqoopoopoqpqppqoqoqoopopopqpoooppoqppqoooqqoooppqqopqopoqqqpqoqqopoqpopopqqpqppqqqpqpqqpqqoqooppqqpoopqqqqqpoppqoqqpqqqqopqqoqqpoppoopqpqoppooppqpqoqqppqqoooooopqqooqpppoopqqpppoooppqoopqoopopqqoopoqooppppooqqqoqqpooqqqqqqqqoooqp...
output:
50000 19 13 12 11 10 10 9 9 9 9 8 8 8 8 8 8 8 8 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 0 6 0 0 0 0 6 6 0 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 0 6 6 6 6 6 0 6 6 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 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 single line: '50000 19 13 12 11 10 10 9 9 9 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #20:
score: 0
Accepted
time: 53ms
memory: 23904kb
input:
opqoqppqqqqoqopqoqqqpqpqpqoqooopqpoqqqpopqqooppooppooopooooppppqpoqqqoqpoooppqqpooopoqpoppqooqpoooqppoopqpqqooooqooqqqoqqoqqqqopooooqqpqqooqppopooopoopopqpqqqqoqppqopqpqoqoooooqpqooqqqoopoopopqqqqoqqqpppoopqqqqoopoqqqooqoqqppppoppppqooqoppqoopqqppopqqoqppoppooopqpqpopqqoqoopoqqqqooqppoqqpoooqqqqooqq...
output:
50000 19 13 12 11 10 9 9 9 9 9 8 9 8 8 8 8 8 8 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 0 6 0 0 6 0 6 0 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 0 6 6 0 0 6 0 0 6 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 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 single line: '50000 19 13 12 11 10 9 9 9 9 9... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #21:
score: 0
Accepted
time: 78ms
memory: 24344kb
input:
qrqqqrqrrqrrqqqqqqrrrqqrqrrrqqrrqqqqrqrqqrqrrqrrrrqrqrrrrqqrqqqqrrrrqqrrrrrqrrqqrqqqqqrqrqrqrqrqqrrrqrrrrrrqrrrrqqrqrqrqqqqqrrrrqqrrqqqrrrqrqrqqqqrrqrqqqrqqqqrrrqqqqqqqqqqrqrrrrqrrqqrrrrqrqqqrqqqrrqqrqqrrqqqrrrqqqrrrqqrrqqqrrqqqqqrqqqrrrrrqrrqrqrrrqrqqqrrqqqqrrrrqqrqrqqrqqrqqqqqqqrrqrrqrrqrrqrrrqrqr...
output:
50000 28 21 18 17 16 15 15 14 14 14 13 13 13 13 13 12 12 12 12 12 12 12 12 12 12 11 11 11 11 11 11 11 11 11 11 11 11 11 11 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 0 0 0 10 10 9 9 9 9 0 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 ...
result:
ok single line: '50000 28 21 18 17 16 15 15 14 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #22:
score: 0
Accepted
time: 72ms
memory: 29132kb
input:
dddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddd...
output:
50000 15040 15039 15038 15037 15036 15035 15034 15033 15032 15031 15030 15029 15028 15027 15026 15025 15024 15023 15022 15021 15020 15019 15018 15017 15016 15015 15014 15013 15012 15011 15010 15009 15008 15007 15006 15005 15004 15003 15002 15001 15000 14999 14998 14997 14996 14995 14994 14993 14992 ...
result:
ok single line: '50000 15040 15039 15038 15037 ... 3 0 0 0 0 2 0 0 0 0 1 0 0 0 0 '
Test #23:
score: 0
Accepted
time: 70ms
memory: 30680kb
input:
cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc...
output:
50000 10373 10372 10371 10370 10369 10368 10367 10366 10365 10364 10363 10362 10361 10360 10359 10358 10357 10356 10355 10354 10353 10352 10351 10350 10349 10348 10347 10346 10345 10344 10343 10342 10341 10340 10339 10338 10337 10336 10335 10334 10333 10332 10331 10330 10329 10328 10327 10326 10325 ...
result:
ok single line: '50000 10373 10372 10371 10370 ... 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 '
Test #24:
score: 0
Accepted
time: 67ms
memory: 30604kb
input:
hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh...
output:
50000 5349 2526 13898 13897 13896 13895 13894 13893 13892 13891 13890 13889 13888 13887 13886 13885 13884 13883 13882 13881 13880 13879 13878 13877 13876 13875 13874 13873 13872 13871 13870 13869 13868 13867 13866 13865 13864 13863 13862 13861 13860 13859 13858 13857 13856 13855 13854 13853 13852 13...
result:
ok single line: '50000 5349 2526 13898 13897 13... 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 '
Test #25:
score: 0
Accepted
time: 71ms
memory: 34280kb
input:
uuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuuu...
output:
50000 19471 19470 19469 19468 19467 19466 19465 19464 19463 19462 19461 19460 19459 19458 19457 19456 19455 19454 19453 19452 19451 19450 19449 19448 19447 19446 19445 19444 19443 19442 19441 19440 19439 19438 19437 19436 19435 19434 19433 19432 19431 19430 19429 19428 19427 19426 19425 19424 19423 ...
result:
ok single line: '50000 19471 19470 19469 19468 ... 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 '
Test #26:
score: 0
Accepted
time: 67ms
memory: 30404kb
input:
hhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh...
output:
50000 8164 10342 10341 10340 10339 10338 10337 10336 10335 10334 10333 10332 10331 10330 10329 10328 10327 10326 10325 10324 10323 10322 10321 10320 10319 10318 10317 10316 10315 10314 10313 10312 10311 10310 10309 10308 10307 10306 10305 10304 10303 10302 10301 10300 10299 10298 10297 10296 10295 1...
result:
ok single line: '50000 8164 10342 10341 10340 1... 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 '
Test #27:
score: 0
Accepted
time: 69ms
memory: 28620kb
input:
dddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddd...
output:
50000 17173 17518 17517 17516 17515 17514 17513 17512 17511 17510 17509 17508 17507 17506 17505 17504 17503 17502 17501 17500 17499 17498 17497 17496 17495 17494 17493 17492 17491 17490 17489 17488 17487 17486 17485 17484 17483 17482 17481 17480 17479 17478 17477 17476 17475 17474 17473 17472 17471 ...
result:
ok single line: '50000 17173 17518 17517 17516 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #28:
score: 0
Accepted
time: 67ms
memory: 25088kb
input:
bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb...
output:
50000 17084 15615 0 0 1470 0 0 4285 0 0 4284 0 0 4283 0 0 4282 0 0 4281 0 0 4280 0 0 4279 0 0 4278 0 0 4277 0 0 4276 0 0 4275 0 0 4274 0 0 4273 0 0 4272 0 0 4271 0 0 4270 0 0 4269 0 0 4268 0 0 4267 0 0 4266 0 0 4265 0 0 4264 0 0 4263 0 0 4262 0 0 4261 0 0 4260 0 0 4259 0 0 4258 0 0 4257 0 0 4256 0 0...
result:
ok single line: '50000 17084 15615 0 0 1470 0 0... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #29:
score: 0
Accepted
time: 70ms
memory: 28820kb
input:
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff...
output:
50000 16185 16183 15958 0 15957 0 15956 0 15955 0 15954 0 15953 0 15952 0 15951 0 15950 0 15949 0 15948 0 15947 0 15946 0 15945 0 15944 0 15943 0 15942 0 15941 0 15940 0 15939 0 15938 0 15937 0 15936 0 15935 0 15934 0 15933 0 15932 0 15931 0 15930 0 15929 0 15928 0 15927 0 15926 0 15925 0 15924 0 15...
result:
ok single line: '50000 16185 16183 15958 0 1595... 0 2 0 0 0 0 0 0 1 0 0 0 0 0 0 '
Test #30:
score: 0
Accepted
time: 64ms
memory: 26912kb
input:
mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm...
output:
50000 11875 10728 10726 7097 7096 7095 716 7093 7092 7091 7090 7089 7088 7087 7086 7085 7084 7083 7082 7081 7080 7079 7078 7077 7076 7075 7074 7073 7072 7071 7070 7069 7068 7067 7066 7065 7064 7063 7062 7061 7060 7059 7058 7057 7056 7055 7054 7053 7052 7051 7050 7049 7048 7047 7046 7045 7044 7043 70...
result:
ok single line: '50000 11875 10728 10726 7097 7... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #31:
score: 0
Accepted
time: 66ms
memory: 28228kb
input:
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq...
output:
50000 15095 14214 9589 9588 9587 9586 9585 9584 9583 9582 9581 9580 9579 9578 9577 9576 9575 9574 9573 9572 9571 9570 9569 9568 9567 9566 9565 9564 9563 9562 9561 9560 9559 9558 9557 9556 9555 9554 9553 9552 9551 9550 9549 9548 9547 9546 9545 9544 9543 9542 9541 9540 9539 9538 9537 9536 9535 9534 95...
result:
ok single line: '50000 15095 14214 9589 9588 95... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #32:
score: 0
Accepted
time: 66ms
memory: 23308kb
input:
llllllllllllllllllllllllllllllllllllllllllllllllllllllllylllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllalllllllllljllllllllllllll...
output:
50000 2445 1515 1460 1049 1047 1044 947 947 938 947 474 1038 473 575 577 574 574 573 474 474 575 575 574 575 0 0 574 573 573 572 573 572 473 473 572 572 572 0 0 571 472 472 571 0 571 571 0 0 570 471 471 0 0 0 570 569 0 0 569 569 569 470 470 0 568 568 568 0 0 0 469 469 0 567 567 0 0 468 468 0 0 0 566...
result:
ok single line: '50000 2445 1515 1460 1049 1047... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #33:
score: 0
Accepted
time: 80ms
memory: 23328kb
input:
eeeeeeeeeeeeeeeeeeeeefeegeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeereeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeefeegeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee...
output:
50000 1375 947 749 739 737 732 540 538 539 538 537 535 533 531 530 430 430 421 420 417 418 418 418 418 417 327 326 123 207 327 325 328 325 0 0 216 216 328 327 326 0 325 327 327 324 0 0 326 324 325 326 326 0 215 215 0 324 325 325 0 0 0 323 324 0 0 323 0 0 0 323 323 324 214 214 0 0 323 0 0 0 323 0 322...
result:
ok single line: '50000 1375 947 749 739 737 732... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #34:
score: 0
Accepted
time: 67ms
memory: 23320kb
input:
wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww...
output:
50000 3940 3239 2565 2379 2377 1702 1717 849 1532 858 1530 858 1531 858 1530 858 1529 1529 1528 1529 1528 858 1528 1527 1526 1527 854 1526 1526 1525 1525 854 0 0 1524 1524 852 0 1523 0 1523 851 0 0 0 1522 850 0 0 0 0 0 0 0 1521 849 849 0 0 0 0 0 0 0 0 0 0 0 678 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok single line: '50000 3940 3239 2565 2379 2377... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #35:
score: 0
Accepted
time: 63ms
memory: 23456kb
input:
ddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddvddddddddddddddddddddddddddddddddddddddddddqdddddddddddddddddddddjdddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddadddddddddddddddddddddddddddddddddddwdddddddddddddddd...
output:
50000 2128 1730 1329 935 932 932 931 930 923 911 805 805 805 799 799 401 405 405 532 533 531 531 315 530 530 404 404 310 532 529 307 306 530 403 403 302 530 530 529 528 529 528 295 529 529 402 402 528 528 528 287 286 285 527 528 527 527 527 279 527 526 276 401 401 526 272 271 526 269 400 400 266 265...
result:
ok single line: '50000 2128 1730 1329 935 932 9... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #36:
score: 0
Accepted
time: 73ms
memory: 23276kb
input:
qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqrqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq...
output:
50000 2440 2431 2427 1825 1821 1820 1216 1216 1221 1220 1217 1219 1218 1217 613 1217 1217 1216 1216 1216 1215 613 1215 1215 1215 1215 0 1214 1214 611 1214 0 1213 0 1213 1213 610 0 0 1212 1212 609 0 0 611 1211 608 0 1211 1211 0 0 0 1210 1210 1210 607 0 0 0 1209 606 0 1209 0 0 0 0 0 0 1208 605 0 0 0 6...
result:
ok single line: '50000 2440 2431 2427 1825 1821... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #37:
score: 0
Accepted
time: 99ms
memory: 23316kb
input:
rzrrrrrrrrrrrrrzrrrrrrrrrrrrrrrrzrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrzrrrrrrrrrrrrrzrrrrrrrrrrrrrrrrzrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrzrrrrrrrrrrrrrzrrrr...
output:
50000 481 373 344 326 307 267 252 251 249 249 247 246 244 242 240 234 233 232 230 213 228 227 225 215 212 207 204 201 216 222 154 212 154 201 209 206 201 204 152 200 198 197 193 152 200 199 185 198 152 179 175 152 197 195 183 145 188 177 173 145 181 181 176 172 145 175 171 143 189 196 186 184 141 14...
result:
ok single line: '50000 481 373 344 326 307 267 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #38:
score: 0
Accepted
time: 110ms
memory: 23420kb
input:
tttttttttttttnttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttnttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttnttttttttttttttttttttttttttttttttttttttnttttttttttttttttttttttttt...
output:
50000 357 300 287 273 257 239 236 235 231 231 230 227 226 224 222 221 220 218 215 214 212 210 208 201 207 206 204 200 198 197 196 195 194 199 199 197 121 197 197 196 195 121 194 193 187 186 183 182 191 185 119 175 186 185 119 174 174 173 171 152 173 172 119 170 169 169 168 171 152 179 168 178 116 16...
result:
ok single line: '50000 357 300 287 273 257 239 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #39:
score: 0
Accepted
time: 103ms
memory: 23352kb
input:
ccccccxccccccccxcccccccccccccccxcccccccxccccccccccccccccccccccxccccccccxcccccccccccccccxcccccccxcccccccccccccccccccccccccccccccccccccccccccccccccccccccccccxccccccccxcccccccccccccccxcccccccxccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccxcccccccc...
output:
50000 385 305 284 269 249 233 228 220 218 217 216 195 188 190 182 160 187 186 182 181 199 175 137 167 193 190 179 174 170 166 146 135 187 186 184 182 160 148 149 171 141 145 133 168 167 133 165 164 163 158 133 158 157 137 155 133 163 154 155 136 149 135 133 136 142 134 131 134 138 133 131 139 132 13...
result:
ok single line: '50000 385 305 284 269 249 233 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #40:
score: 0
Accepted
time: 109ms
memory: 23460kb
input:
zzzzzzzzzzzzpzzzzzzzzzzzzzzzzzzpzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzpzzzzzzzzzzzzzzzzzzpzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzpzzzzzzzzzzzzzzzzzzpzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz...
output:
50000 358 298 290 283 278 258 249 246 223 213 209 207 207 205 204 203 201 201 200 198 198 198 197 196 195 194 194 176 172 191 121 189 182 188 179 183 182 181 181 180 179 177 176 176 175 175 174 121 173 172 119 171 170 172 170 169 168 166 168 167 168 165 164 119 166 167 164 163 162 163 122 116 121 15...
result:
ok single line: '50000 358 298 290 283 278 258 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '
Test #41:
score: 0
Accepted
time: 99ms
memory: 23296kb
input:
fffffffffffffffffffffffffffffffffffffffffffffffffffffnffffffffffffnfffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffnffffffffffffnffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffnffffffffffffn...
output:
50000 513 371 357 346 318 297 288 274 271 242 270 236 216 235 229 226 266 216 214 263 262 160 258 255 212 158 205 158 201 253 253 158 249 250 246 158 206 158 201 218 198 158 221 217 158 216 152 208 206 204 148 212 207 148 194 193 192 202 148 148 203 201 191 198 200 143 202 191 200 190 190 205 189 14...
result:
ok single line: '50000 513 371 357 346 318 297 ... 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 '