QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#199275#6364. The Most Expensive GiftgondozuAC ✓451ms3748kbC++141.1kb2023-10-04 02:13:222023-10-04 02:13:22

Judging History

你现在查看的是最新测评结果

  • [2023-10-04 02:13:22]
  • 评测
  • 测评结果:AC
  • 用时:451ms
  • 内存:3748kb
  • [2023-10-04 02:13:22]
  • 提交

answer

#include <bits/stdc++.h>
#define pb push_back
#define F first
#define S second
#define all(v) v.begin(),v.end()
#define Gondozu ios::sync_with_stdio(false);cout.tie(NULL);cin.tie(NULL);

using namespace std;
using ll = long long;
using pi = pair<int, int>;
using vi = vector<int>;
using vpi = vector <pair<int, int>>;
using vvi = vector <vector<int>>;

const int OO = 1e9 + 5;
const int N = 2e5 + 5;

string cur, s;
int n, ans;
void gen(int i){
    // eval cur

    if(i != 0){
        int idx = 0, len = 0;
        for (int j = 0; j < n; ++j) {
            if(s[j] == cur[idx]){
                (++idx) %= i;
                if(idx==0) len += i;
            }
        }
        ans = max(ans, len * len / i);
    }

    if(i == min(8,n))
        return;
    for (char c = 'a'; c <= 'c'; ++c) {
        cur.pb(c);
        gen(i+1);
        cur.pop_back();
    }
}

void TC()
{
    cin >> n >> s;
    ans = ((n+2)/3) * ((n+2)/3);
    gen(0);
    cout << ans;
}

int32_t main() {
    Gondozu
    int t = 1;
//    cin >> t;
    while (t--) {
        TC();
        cout << '\n';
    }
    return 0;
}

这程序好像有点Bug,我给组数据试试?

详细

Test #1:

score: 100
Accepted
time: 1ms
memory: 3668kb

input:

11
abcabacbcac

output:

18

result:

ok 1 number(s): "18"

Test #2:

score: 0
Accepted
time: 0ms
memory: 3608kb

input:

10
aaaaaaaaaa

output:

100

result:

ok 1 number(s): "100"

Test #3:

score: 0
Accepted
time: 0ms
memory: 3660kb

input:

10
aabbbabbba

output:

36

result:

ok 1 number(s): "36"

Test #4:

score: 0
Accepted
time: 1ms
memory: 3648kb

input:

10
acaabbacbb

output:

16

result:

ok 1 number(s): "16"

Test #5:

score: 0
Accepted
time: 0ms
memory: 3660kb

input:

10
abbabaabba

output:

25

result:

ok 1 number(s): "25"

Test #6:

score: 0
Accepted
time: 1ms
memory: 3644kb

input:

10
abcbcacabb

output:

16

result:

ok 1 number(s): "16"

Test #7:

score: 0
Accepted
time: 0ms
memory: 3648kb

input:

10
cbccbcbccb

output:

36

result:

ok 1 number(s): "36"

Test #8:

score: 0
Accepted
time: 0ms
memory: 3584kb

input:

10
abaabaabaa

output:

49

result:

ok 1 number(s): "49"

Test #9:

score: 0
Accepted
time: 1ms
memory: 3632kb

input:

10
abaabaabaa

output:

49

result:

ok 1 number(s): "49"

Test #10:

score: 0
Accepted
time: 1ms
memory: 3644kb

input:

10
bcbcbcbcbc

output:

50

result:

ok 1 number(s): "50"

Test #11:

score: 0
Accepted
time: 1ms
memory: 3640kb

input:

10
aacacbaaca

output:

36

result:

ok 1 number(s): "36"

Test #12:

score: 0
Accepted
time: 0ms
memory: 3584kb

input:

10
aaaaaacaab

output:

64

result:

ok 1 number(s): "64"

Test #13:

score: 0
Accepted
time: 0ms
memory: 3588kb

input:

10
acacacacac

output:

50

result:

ok 1 number(s): "50"

Test #14:

score: 0
Accepted
time: 1ms
memory: 3584kb

input:

10
abacabacab

output:

25

result:

ok 1 number(s): "25"

Test #15:

score: 0
Accepted
time: 0ms
memory: 3592kb

input:

10
aaabaaabaa

output:

64

result:

ok 1 number(s): "64"

Test #16:

score: 0
Accepted
time: 1ms
memory: 3712kb

input:

10
ababacabab

output:

32

result:

ok 1 number(s): "32"

Test #17:

score: 0
Accepted
time: 0ms
memory: 3660kb

input:

10
aaaaabaaaa

output:

81

result:

ok 1 number(s): "81"

Test #18:

score: 0
Accepted
time: 0ms
memory: 3580kb

input:

10
aaaaaaaaaa

output:

100

result:

ok 1 number(s): "100"

Test #19:

score: 0
Accepted
time: 0ms
memory: 3632kb

input:

10
aaaaaaabaa

output:

81

result:

ok 1 number(s): "81"

Test #20:

score: 0
Accepted
time: 1ms
memory: 3632kb

input:

10
abacabacab

output:

25

result:

ok 1 number(s): "25"

Test #21:

score: 0
Accepted
time: 1ms
memory: 3632kb

input:

100
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

output:

10000

result:

ok 1 number(s): "10000"

Test #22:

score: 0
Accepted
time: 1ms
memory: 3708kb

input:

100
abaaabaabaabbabbabbaaabbbbbbabbbababaaaaabbaaabbbababbbaabaabababababbbabaaaababaababbabbbabbbabaabb

output:

2704

result:

ok 1 number(s): "2704"

Test #23:

score: 0
Accepted
time: 3ms
memory: 3648kb

input:

100
ccbcbcccbcbbbabaabcacbbabbbcbcbcbabbbababbcbaccaacbaabbbccccbcbabcbbcacbbbcaacababbacbaaaaacbaaaacbc

output:

1681

result:

ok 1 number(s): "1681"

Test #24:

score: 0
Accepted
time: 1ms
memory: 3660kb

input:

100
abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabba

output:

2500

result:

ok 1 number(s): "2500"

Test #25:

score: 0
Accepted
time: 5ms
memory: 3644kb

input:

100
abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaa

output:

1156

result:

ok 1 number(s): "1156"

Test #26:

score: 0
Accepted
time: 1ms
memory: 3576kb

input:

100
acaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacaacacaacacaaca

output:

3844

result:

ok 1 number(s): "3844"

Test #27:

score: 0
Accepted
time: 1ms
memory: 3648kb

input:

100
abaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaabab

output:

4096

result:

ok 1 number(s): "4096"

Test #28:

score: 0
Accepted
time: 2ms
memory: 3708kb

input:

100
abaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaa

output:

4489

result:

ok 1 number(s): "4489"

Test #29:

score: 0
Accepted
time: 0ms
memory: 3660kb

input:

100
bcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbc

output:

5000

result:

ok 1 number(s): "5000"

Test #30:

score: 0
Accepted
time: 4ms
memory: 3644kb

input:

100
bacccbacacbcbababbcabbbbbabacbabcbaacbbbbbbaabbbcbabcbbbbcabbcababccbcbabbcbbbaacbccbbabbbbbbbacbbbb

output:

3136

result:

ok 1 number(s): "3136"

Test #31:

score: 0
Accepted
time: 2ms
memory: 3704kb

input:

100
bcabbabbcbbbbbbbbbbbbcbbcbbbcbbbbbbbbbcbabacbabababbcbbbbbcbbabbbbbaabbbbbbbbbbbbbcbbbbbacabcbbbbbbb

output:

5776

result:

ok 1 number(s): "5776"

Test #32:

score: 0
Accepted
time: 1ms
memory: 3596kb

input:

100
abababababababababababababababababababababababababababababababababababababababababababababababababab

output:

5000

result:

ok 1 number(s): "5000"

Test #33:

score: 0
Accepted
time: 3ms
memory: 3596kb

input:

100
cbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbca

output:

2500

result:

ok 1 number(s): "2500"

Test #34:

score: 0
Accepted
time: 3ms
memory: 3584kb

input:

100
aaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaab

output:

5776

result:

ok 1 number(s): "5776"

Test #35:

score: 0
Accepted
time: 3ms
memory: 3660kb

input:

100
ababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaabab

output:

2916

result:

ok 1 number(s): "2916"

Test #36:

score: 0
Accepted
time: 1ms
memory: 3644kb

input:

100
aaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaa

output:

7056

result:

ok 1 number(s): "7056"

Test #37:

score: 0
Accepted
time: 1ms
memory: 3644kb

input:

100
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

output:

10000

result:

ok 1 number(s): "10000"

Test #38:

score: 0
Accepted
time: 2ms
memory: 3588kb

input:

100
aaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaa

output:

7744

result:

ok 1 number(s): "7744"

Test #39:

score: 0
Accepted
time: 3ms
memory: 3576kb

input:

100
abacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabac

output:

3364

result:

ok 1 number(s): "3364"

Test #40:

score: 0
Accepted
time: 5ms
memory: 3644kb

input:

1000
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

1000000

result:

ok 1 number(s): "1000000"

Test #41:

score: 0
Accepted
time: 7ms
memory: 3648kb

input:

1000
bababbbababaabbbbababaaabbabbaabaabbabbbbbbbabbbabbbababbbbabaabbbabbaaaaaabbaababbbabbaaaabaababaaabbbbbaabaabbaabbaabbabbbabbbaaaaabbabbbbbbabaaaaabaaabaaabababaaaaababbbaabbaaaaabbbbaabaaaaabaabbaaabbabbbbababbabbbaaaaaaaabbbababaaabaabaabbaababaaabbababbaaaabbbaaabbbaabbababbaaaaabbbaababab...

output:

260100

result:

ok 1 number(s): "260100"

Test #42:

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

input:

1000
acbbcacabacccbabcabccccccbaabccaccbcbacccabbaaacbcbbaccbcabcaacbbbbcccabcccbacccabbbcaaacbaabbaccacaccabbbbbbbacaabaaaacaaaaaaabccabbcaaaaabcacabbacacacaaabccbaabbbaccccaaaabbaccbacabccacbbbacbabcabaaacbcacabacbacbaaaabcbcaaaccacaaabbabaabbcaccbcccbccabcabaccbcccbbacbbaabccabccacabbcabccabaaabb...

output:

116964

result:

ok 1 number(s): "116964"

Test #43:

score: 0
Accepted
time: 6ms
memory: 3648kb

input:

1000
abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaababbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaa...

output:

250000

result:

ok 1 number(s): "250000"

Test #44:

score: 0
Accepted
time: 44ms
memory: 3704kb

input:

1000
abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcacababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacaba...

output:

111556

result:

ok 1 number(s): "111556"

Test #45:

score: 0
Accepted
time: 7ms
memory: 3588kb

input:

1000
abaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaababaabaabab...

output:

381924

result:

ok 1 number(s): "381924"

Test #46:

score: 0
Accepted
time: 6ms
memory: 3648kb

input:

1000
abaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaaba...

output:

413449

result:

ok 1 number(s): "413449"

Test #47:

score: 0
Accepted
time: 3ms
memory: 3644kb

input:

1000
abaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaa...

output:

444889

result:

ok 1 number(s): "444889"

Test #48:

score: 0
Accepted
time: 6ms
memory: 3592kb

input:

1000
bcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcb...

output:

500000

result:

ok 1 number(s): "500000"

Test #49:

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

input:

1000
cabaccccbbbaccaccbccbccbbbaccbcccbccbbcacabcaccacaccaacbcbacbcbcabbbbcaccabbcccbacaabccbbccacccbbccbcbbbbcccaccbbbcbcbcccacbcacaaacbbbcbcccaacbbbbcacacbccacabcbbccaababccbccbccbcacabcacaacccbcbcbbcaccccbbacccccacbcacaccbabccccabcacccabbacaccccbcccccaabcccaccabcccacaccacccbbaabcccccccaabcabaccab...

output:

267289

result:

ok 1 number(s): "267289"

Test #50:

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

input:

1000
bcccacccabcabacccccccccccccabccacccccccbbacaccaccccaacacccccccaaccbaacccbccaccaaccbccaccaacbcccccbccacacccccaccacccccacaacabbbaccccbccaacaccaccacbccccacccbacccaacccaacacccccccccccccccbbacacccacacaacccbccacbccccccaccaccccaacacbccaaccacaaaaacacccacacccacabaccabcccabacccaaccccaacacccccccccbbccccaa...

output:

408321

result:

ok 1 number(s): "408321"

Test #51:

score: 0
Accepted
time: 7ms
memory: 3644kb

input:

1000
bababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababab...

output:

500000

result:

ok 1 number(s): "500000"

Test #52:

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

input:

1000
cacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcac...

output:

250000

result:

ok 1 number(s): "250000"

Test #53:

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

input:

1000
aaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaabaaabaaabaaabaaacaaabaaabaaabaaacaaabaaa...

output:

580644

result:

ok 1 number(s): "580644"

Test #54:

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

input:

1000
ababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababaca...

output:

284089

result:

ok 1 number(s): "284089"

Test #55:

score: 0
Accepted
time: 9ms
memory: 3664kb

input:

1000
aaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaaaaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaaba...

output:

702244

result:

ok 1 number(s): "702244"

Test #56:

score: 0
Accepted
time: 4ms
memory: 3644kb

input:

899
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

808201

result:

ok 1 number(s): "808201"

Test #57:

score: 0
Accepted
time: 9ms
memory: 3648kb

input:

1000
aaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaaaaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaa...

output:

774400

result:

ok 1 number(s): "774400"

Test #58:

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

input:

1000
abacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacaba...

output:

339889

result:

ok 1 number(s): "339889"

Test #59:

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

input:

9995
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

99900025

result:

ok 1 number(s): "99900025"

Test #60:

score: 0
Accepted
time: 71ms
memory: 3668kb

input:

9995
bababaaabaabaabbabbabbaaabbbbbbabbbababaaaaabbaaabbbababbbaabaabababababbbabaaaababaababbabbbabbbabaabbbbbaababaaaabaaaaaabaabbaaaabbaaababbbabbaabaababbbaabbbbaabbbbabbaabbabababaaabaababaabaabababbabbbabaaabaaabaabbaabbaabababaaaaabaabbabbbaaaabbbabbabbbaaabaaaabbbbaabbaaaabaabbaaaaaababbbaaa...

output:

25391521

result:

ok 1 number(s): "25391521"

Test #61:

score: 0
Accepted
time: 448ms
memory: 3644kb

input:

9995
aaccabbbcbbbcacaacbbccbbbccacabcaccbaccbccbaaaabbbcabbcbbbcabcaabbcbacccaabbcbcbcbccccccccccccccacbccaaaabacbbccbbcccbbcbacbcaabcbbcaccbbcabaabaacaacccbcbaaacbacacbabcaaaaabbbbcaaccaababbcabacbcaacbaababbacaaababacaaabcaacbaababbaabacababacaccbabbccaaaacbaacbcbbcbaccbbccbbccbaaaaabbacbacabbbbaa...

output:

11202409

result:

ok 1 number(s): "11202409"

Test #62:

score: 0
Accepted
time: 54ms
memory: 3668kb

input:

9995
abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaababbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaa...

output:

24980004

result:

ok 1 number(s): "24980004"

Test #63:

score: 0
Accepted
time: 308ms
memory: 3732kb

input:

9995
abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcacababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacaba...

output:

11102224

result:

ok 1 number(s): "11102224"

Test #64:

score: 0
Accepted
time: 52ms
memory: 3736kb

input:

9995
bcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbbcbcbbcbcbbcbbcbcbbcbcbbcbbcbc...

output:

38155329

result:

ok 1 number(s): "38155329"

Test #65:

score: 0
Accepted
time: 57ms
memory: 3596kb

input:

9995
abaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaaba...

output:

41293476

result:

ok 1 number(s): "41293476"

Test #66:

score: 0
Accepted
time: 57ms
memory: 3612kb

input:

9995
abaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaa...

output:

44395569

result:

ok 1 number(s): "44395569"

Test #67:

score: 0
Accepted
time: 60ms
memory: 3608kb

input:

9995
bcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcb...

output:

49940018

result:

ok 1 number(s): "49940018"

Test #68:

score: 0
Accepted
time: 413ms
memory: 3616kb

input:

9995
caccaacabcacccabaaaabcbcaacbccbacaabbaaacabcacaacbaccabccbbbcaacbabaababbaababacababaaabaccbaacacccaaacaabbbcabbcabcccacbcbaaabbcbaabbbaabaacacbbaacacaacbabbccbaacacbacacacbcbcabcaaaaaaaabaaaabaacabbacabaaaabaaacbacacacbabacbacbbcaaacaaaccaabbabcabbbccaaccacaccabcbbbaacbbbaaacccaacacabbabacccaa...

output:

24561936

result:

ok 1 number(s): "24561936"

Test #69:

score: 0
Accepted
time: 287ms
memory: 3632kb

input:

9995
acaaaaaababaaaababbaacacbbacaaaaaaccbabbacabbaabaaaababbbbaaacaabcbaaacababaaaabaaaaaacaacabbbabbcbaaaaaabbaaacbabcbaaaabbaaabbabbacaaababababbaaaaaaaacaabaaabaaaababacacaaaabacaaabaabbaabbbaaaaaaaaabbabaaacacccaaabbcaaaacaacacbbbaaaaaaacabaaabbaaaaaaaaaaaaabaabbabaacaaaacaaabcaaacbabbbaabbbaab...

output:

44568976

result:

ok 1 number(s): "44568976"

Test #70:

score: 0
Accepted
time: 55ms
memory: 3612kb

input:

9995
acacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacaca...

output:

49940018

result:

ok 1 number(s): "49940018"

Test #71:

score: 0
Accepted
time: 246ms
memory: 3732kb

input:

9995
abacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacaba...

output:

24980004

result:

ok 1 number(s): "24980004"

Test #72:

score: 0
Accepted
time: 104ms
memory: 3696kb

input:

9995
aaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaabaaabaaabaaabaaacaaabaaabaaabaaacaaabaaa...

output:

58003456

result:

ok 1 number(s): "58003456"

Test #73:

score: 0
Accepted
time: 192ms
memory: 3732kb

input:

9995
ababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababaca...

output:

28430224

result:

ok 1 number(s): "28430224"

Test #74:

score: 0
Accepted
time: 71ms
memory: 3656kb

input:

9995
aaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaaaaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaaba...

output:

70040161

result:

ok 1 number(s): "70040161"

Test #75:

score: 0
Accepted
time: 4ms
memory: 3568kb

input:

899
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

808201

result:

ok 1 number(s): "808201"

Test #76:

score: 0
Accepted
time: 75ms
memory: 3732kb

input:

9995
aaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaaaaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaa...

output:

77281681

result:

ok 1 number(s): "77281681"

Test #77:

score: 0
Accepted
time: 207ms
memory: 3616kb

input:

9995
abacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacaba...

output:

33988900

result:

ok 1 number(s): "33988900"

Test #78:

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

input:

9996
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

99920016

result:

ok 1 number(s): "99920016"

Test #79:

score: 0
Accepted
time: 72ms
memory: 3672kb

input:

9996
aabaabbaaababbbbabbaabaaabababaaaabbbababbbaaaaabaabbaabaabaabbaaabbbabbbbabaaabaaaabbbbbaaaaabbaabbbbabaabaaaabbbbaabbaabbbbaaaaaabababaabaabbabbabbabaaaababababababbaabababbaabaabbaababbbaaabaaabababaabaaaababbaaabaabaaababbbaabbabaababbababaabbbbaababbababaaaababbaaaaaaabbbbaaaababababaabbba...

output:

25270729

result:

ok 1 number(s): "25270729"

Test #80:

score: 0
Accepted
time: 446ms
memory: 3732kb

input:

9996
accbbcbbccbcbcccaccaacaabbbaaaaacacaaababbcbcbaccaabbbbbaaacabbacaabbcbbccacbbcbccabcccabacbacacaccacccbcabbccaababbbacbccccabbcabcbacaacacaccbbbccbccbcbabbcbbcbbabacbaccbccbbacbabbabbaccbababcbcbabacabaaaaaaaccbbbbaccaabbbbacbbbccbbbcacccaabbbcbcaacacabbbaabacccbcbbcbbcccbcaaacaabacccbbcbcbbaa...

output:

11209104

result:

ok 1 number(s): "11209104"

Test #81:

score: 0
Accepted
time: 58ms
memory: 3668kb

input:

9996
abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaababbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaa...

output:

24980004

result:

ok 1 number(s): "24980004"

Test #82:

score: 0
Accepted
time: 308ms
memory: 3672kb

input:

9996
abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcacababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacaba...

output:

11102224

result:

ok 1 number(s): "11102224"

Test #83:

score: 0
Accepted
time: 58ms
memory: 3732kb

input:

9996
abaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaabaababaababaabaababaababaabaababaabaababaababaabaababaababaabaabab...

output:

38167684

result:

ok 1 number(s): "38167684"

Test #84:

score: 0
Accepted
time: 57ms
memory: 3664kb

input:

9996
abaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaaba...

output:

41293476

result:

ok 1 number(s): "41293476"

Test #85:

score: 0
Accepted
time: 57ms
memory: 3680kb

input:

9996
abaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaa...

output:

44408896

result:

ok 1 number(s): "44408896"

Test #86:

score: 0
Accepted
time: 59ms
memory: 3672kb

input:

9996
bcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcb...

output:

49960008

result:

ok 1 number(s): "49960008"

Test #87:

score: 0
Accepted
time: 409ms
memory: 3620kb

input:

9996
bcbcccabcbcccbbcbccaaacbccbbbcacccacacbcbabccccbcacbcaacbcbacbcaacbcbbcaaaaacbbcaccacaaccabbcaacbacbaaacbbcbaaccbcbccaacacacbabacccccccbaaacccacabcaacccacacbbcccbccbacbcbcbcccbcbaccccbbacbbaacccccaccccacbcccbcccbbacccbcccccbcaabbbacccbacacccbaccbacbcbabcbbaabcaaccbbabccaabbabbccbbaaacccccbccacb...

output:

24206400

result:

ok 1 number(s): "24206400"

Test #88:

score: 0
Accepted
time: 281ms
memory: 3652kb

input:

9996
cbcabbbbabbbbaccbcbbcbbbbbcbcbbbbbababbbbbabcbcbbbbbbcccbcbbbabacbcbabbcbbbcbbbccbcabbbbbbbcabbcbbbbbcbbcbabbbbbbbbbbbcbbbbabbbbbbbbbbbcbbcbbbbbbbbcbbcbbbbcbcbbbabbbccbccbbcbcbbcbbbbcbacbaccbbcccbbbccacbcbccbabbbcbbabccbbbaababbcccccbbbbbbccbbccbbbbbaababbabbbbabcbbbbbbcbbbcbcbbbcccbcbbcbbccbcb...

output:

44542276

result:

ok 1 number(s): "44542276"

Test #89:

score: 0
Accepted
time: 60ms
memory: 3672kb

input:

9996
cbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbc...

output:

49960008

result:

ok 1 number(s): "49960008"

Test #90:

score: 0
Accepted
time: 246ms
memory: 3688kb

input:

9996
acabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabaca...

output:

24980004

result:

ok 1 number(s): "24980004"

Test #91:

score: 0
Accepted
time: 104ms
memory: 3676kb

input:

9996
aaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaabaaabaaabaaabaaacaaabaaabaaabaaacaaabaaa...

output:

58003456

result:

ok 1 number(s): "58003456"

Test #92:

score: 0
Accepted
time: 192ms
memory: 3684kb

input:

9996
ababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababaca...

output:

28430224

result:

ok 1 number(s): "28430224"

Test #93:

score: 0
Accepted
time: 70ms
memory: 3612kb

input:

9996
aaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaaaaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaaba...

output:

70040161

result:

ok 1 number(s): "70040161"

Test #94:

score: 0
Accepted
time: 4ms
memory: 3644kb

input:

899
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

808201

result:

ok 1 number(s): "808201"

Test #95:

score: 0
Accepted
time: 75ms
memory: 3672kb

input:

9996
aaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaaaaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaa...

output:

77299264

result:

ok 1 number(s): "77299264"

Test #96:

score: 0
Accepted
time: 208ms
memory: 3608kb

input:

9996
abacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacaba...

output:

34000561

result:

ok 1 number(s): "34000561"

Test #97:

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

input:

9997
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

99940009

result:

ok 1 number(s): "99940009"

Test #98:

score: 0
Accepted
time: 67ms
memory: 3728kb

input:

9997
aaabaaababaaaabbabaaabaabaaaabaabbaaababababbbbbabaaaaabbabbbaabbabbbbabaabbbababbbbabaaaababaabaabbbbaabaaaabbbaaaabababbbabbbbaabbabbabbbaabaaabbbabbabbababaaaaabbbabbbbbabbaaababbaababbbbbaaaabaabbabaaababbaabaaaaabbbbaabbbbaabaabbabbaabbaababbbaabaaaaabaabbaaabbababaaaabbabbbaaaabbbaabaabba...

output:

25140196

result:

ok 1 number(s): "25140196"

Test #99:

score: 0
Accepted
time: 445ms
memory: 3676kb

input:

9997
caaacccccaccacabbcbcabacbbbcbbcaacccabbbcbcabababbbbcbbcaacbccbaabbbccbcabbaacbbcbccababbcbcbbacacacccabacbabbbacccabaaccabaccabccabaaabcbbbcbcaabbaacbabbacaabbbccbccabbbaabababaaabbaabcaaabacccacbaacaababbccbbbbaaabbacacacacbcbcccaacccccbbbaaaccacbaccbaabccabababcabbbbbaabcbcccababbaaabbccbcba...

output:

11343424

result:

ok 1 number(s): "11343424"

Test #100:

score: 0
Accepted
time: 58ms
memory: 3672kb

input:

9997
abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaababbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaa...

output:

24990001

result:

ok 1 number(s): "24990001"

Test #101:

score: 0
Accepted
time: 304ms
memory: 3684kb

input:

9997
abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcacababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacaba...

output:

11108889

result:

ok 1 number(s): "11108889"

Test #102:

score: 0
Accepted
time: 58ms
memory: 3728kb

input:

9997
caccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccaca...

output:

38180041

result:

ok 1 number(s): "38180041"

Test #103:

score: 0
Accepted
time: 57ms
memory: 3612kb

input:

9997
abaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaaba...

output:

41306329

result:

ok 1 number(s): "41306329"

Test #104:

score: 0
Accepted
time: 57ms
memory: 3668kb

input:

9997
abaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaa...

output:

44422225

result:

ok 1 number(s): "44422225"

Test #105:

score: 0
Accepted
time: 59ms
memory: 3672kb

input:

9997
bcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcb...

output:

49960008

result:

ok 1 number(s): "49960008"

Test #106:

score: 0
Accepted
time: 409ms
memory: 3664kb

input:

9997
bbbbbbccacbbcbbcbcccababcbbbbbcacccbabaabbcbbbbabbcbbcbcabbcaacccbbaccbbcbcabbccbcaaabcbcabbbbbbcbcbbbcbbbbbbcabaaabbabacacbbbbbbccbacaaabbaacaabcbbababbbacbbbcbbbbbbabcccccccbbbbccacbbbabbacabbbcbbbcabbabcbcbbbbcbbbaacabcbcccbabbbbcbbcbbbccbabbbbacbbabcbcacabcbbcabbbabbbbccbacbaacbaabbabbababb...

output:

24820324

result:

ok 1 number(s): "24820324"

Test #107:

score: 0
Accepted
time: 288ms
memory: 3668kb

input:

9997
cccaacccaabcaaccccccbbacaccccbacccabccaccaacbccbcacaccaccacccbaacccccccccccaacacccccabccbcaccccbacbabcccccccacccacccbcbacccbcccbcbccccbcacccccccaacacacccccbcacabcaccaccacacabcacbcccaccacccabccacacccccbcacccccccccacacbcbcacccacacccacbcabccacacacbaccccccccccccccccccccbbbbcabccacaccccacccccccbacba...

output:

44049769

result:

ok 1 number(s): "44049769"

Test #108:

score: 0
Accepted
time: 59ms
memory: 3672kb

input:

9997
cacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacacac...

output:

49960008

result:

ok 1 number(s): "49960008"

Test #109:

score: 0
Accepted
time: 246ms
memory: 3600kb

input:

9997
bcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcb...

output:

24990001

result:

ok 1 number(s): "24990001"

Test #110:

score: 0
Accepted
time: 104ms
memory: 3680kb

input:

9997
aaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaabaaabaaabaaabaaacaaabaaabaaabaaacaaabaaa...

output:

58018689

result:

ok 1 number(s): "58018689"

Test #111:

score: 0
Accepted
time: 192ms
memory: 3624kb

input:

9997
ababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababaca...

output:

28440889

result:

ok 1 number(s): "28440889"

Test #112:

score: 0
Accepted
time: 70ms
memory: 3656kb

input:

9997
aaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaaaaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaaba...

output:

70056900

result:

ok 1 number(s): "70056900"

Test #113:

score: 0
Accepted
time: 4ms
memory: 3648kb

input:

899
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

808201

result:

ok 1 number(s): "808201"

Test #114:

score: 0
Accepted
time: 76ms
memory: 3672kb

input:

9997
aaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaaaaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaa...

output:

77316849

result:

ok 1 number(s): "77316849"

Test #115:

score: 0
Accepted
time: 208ms
memory: 3736kb

input:

9997
abacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacaba...

output:

34012224

result:

ok 1 number(s): "34012224"

Test #116:

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

input:

9998
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

99960004

result:

ok 1 number(s): "99960004"

Test #117:

score: 0
Accepted
time: 71ms
memory: 3684kb

input:

9998
baabbabbbbbabbaabababaaababababbaabbaaaabaabaabababbbbabbbabaabbbbabaababaaabaabababaabaabbbbaabbaabbabaaabaabbbabbbabaabaaaababaabbaaaababbbaababbabaabbaabbbbaabbbabbababbaabbaaaabbbaaaababbabbbbbbbbbaabbbbbaaabbbabaaaaaabaabaabbaaaaababbbabbaaabaababaaabaaaabaabaaababbbaaaaaaabbaaaababbaabaaa...

output:

25240576

result:

ok 1 number(s): "25240576"

Test #118:

score: 0
Accepted
time: 445ms
memory: 3668kb

input:

9998
bcbcbcacabaabbbcccabacaaccacaaabaaaccaabcacbbcbbcbbacbbbaaaaccbbcbabcabcacaccacacbcbbccbbccbaccbabbaabccacbbaabacabcbbacbcbcbbaaaaacabacbccacbbbaaaabcabbcaaacaccaabcbbbccbcccbbabacaabaccbbbcbcaccacbbbcbaacccbccbcccabaaaacaacccacccacbcacaabcaacbbabaaaaaaabaabaacbabbbbcbacabacaabaaccbaabcaaacabcc...

output:

11142244

result:

ok 1 number(s): "11142244"

Test #119:

score: 0
Accepted
time: 58ms
memory: 3684kb

input:

9998
abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaababbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaa...

output:

24990001

result:

ok 1 number(s): "24990001"

Test #120:

score: 0
Accepted
time: 308ms
memory: 3652kb

input:

9998
abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcacababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacaba...

output:

11108889

result:

ok 1 number(s): "11108889"

Test #121:

score: 0
Accepted
time: 59ms
memory: 3732kb

input:

9998
acaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacac...

output:

38180041

result:

ok 1 number(s): "38180041"

Test #122:

score: 0
Accepted
time: 57ms
memory: 3652kb

input:

9998
abaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaaba...

output:

41306329

result:

ok 1 number(s): "41306329"

Test #123:

score: 0
Accepted
time: 57ms
memory: 3648kb

input:

9998
abaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaa...

output:

44422225

result:

ok 1 number(s): "44422225"

Test #124:

score: 0
Accepted
time: 56ms
memory: 3736kb

input:

9998
bcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcb...

output:

49980002

result:

ok 1 number(s): "49980002"

Test #125:

score: 0
Accepted
time: 409ms
memory: 3608kb

input:

9998
aaccbbcababaaabacbbcacbbbbaaaaaaaaacabcccbbbbcaaacbbbaaaaaabbcaacacacacabaabacacaacbacbbbaaacaabbcabaabaabbcbaaaaabcbbaacabacbaaaccbaacacaabaaacbbacbbaaaaabcaccaabaaaaaabbbacacbacabcccaacacbcbabaaaaaabbacbbbbaacacabcaaababbbabaaaaacbababbbaabaabbccaaacbacbaaabcbcaccbcbabaacccbcabaaabcaabcaacaac...

output:

24730729

result:

ok 1 number(s): "24730729"

Test #126:

score: 0
Accepted
time: 288ms
memory: 3648kb

input:

9998
bacbbccbccbcaacccccbccacacacaccccbcaccaacccbcccbccabacccccccbcccccbbbcccbccccccabcbccccccacaccccbcccccccbbabbbabcbcccccaccbcbccbccccccbabbbabccabccccacccacbcbbccaccccbcbbccccccccbbccbcabcaabcacbabcccccacacbccabcccaacccbccbccbbcacbcbccbccbbbabccbcccbacccccccccccabbcbacacbcbccccaccccbccccacbcbbbc...

output:

43877376

result:

ok 1 number(s): "43877376"

Test #127:

score: 0
Accepted
time: 59ms
memory: 3732kb

input:

9998
bababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababab...

output:

49980002

result:

ok 1 number(s): "49980002"

Test #128:

score: 0
Accepted
time: 242ms
memory: 3604kb

input:

9998
babcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbabcbab...

output:

24990001

result:

ok 1 number(s): "24990001"

Test #129:

score: 0
Accepted
time: 104ms
memory: 3664kb

input:

9998
aaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaabaaabaaabaaabaaacaaabaaabaaabaaacaaabaaa...

output:

58033924

result:

ok 1 number(s): "58033924"

Test #130:

score: 0
Accepted
time: 192ms
memory: 3672kb

input:

9998
ababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababaca...

output:

28440889

result:

ok 1 number(s): "28440889"

Test #131:

score: 0
Accepted
time: 70ms
memory: 3688kb

input:

9998
aaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaaaaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaaba...

output:

70073641

result:

ok 1 number(s): "70073641"

Test #132:

score: 0
Accepted
time: 4ms
memory: 3592kb

input:

899
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

808201

result:

ok 1 number(s): "808201"

Test #133:

score: 0
Accepted
time: 75ms
memory: 3688kb

input:

9998
aaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaaaaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaa...

output:

77334436

result:

ok 1 number(s): "77334436"

Test #134:

score: 0
Accepted
time: 207ms
memory: 3684kb

input:

9998
abacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacaba...

output:

34012224

result:

ok 1 number(s): "34012224"

Test #135:

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

input:

9999
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

99980001

result:

ok 1 number(s): "99980001"

Test #136:

score: 0
Accepted
time: 69ms
memory: 3668kb

input:

9999
abababbabbaaaaaabaaabaabaabbbabbbbbbaabaabbbbbababaaabababbabbaababbabaabaaabaaaabbababbbbabaabbbaaaaaaaaaaabbabbbaaabaabbabbaabbabaababaaabbbbbbbababbbabbbababaabbbbaaaaabbaababaaabaabbabababaabaabbbababaabbabbbababbaabbbabbbbbbbbabbaabbaaaaababaabbaababbbabbbaaaaabaabaabbaabaaaaababbbaabbbaaa...

output:

25959025

result:

ok 1 number(s): "25959025"

Test #137:

score: 0
Accepted
time: 451ms
memory: 3672kb

input:

9999
babababacccabaababcabbcaabccacaacbcabbccbbcbabacbaaacbcabbcabaaaabbcaabbcacaaaaabacaabbcaacbbcabccccbabcbababacabaacbacabaaabbbababaabcbbccbcbaabaccccbbbbacbcbacaccbccaabcccbabbcaccaabaacaabcabbcaaccbabccaacaabacabcbcabbabcaaacccabbaacbbbcabccccacbabbccbcbbbcbbaabaaaacaababcacacccbcbaacbbaccabb...

output:

11682724

result:

ok 1 number(s): "11682724"

Test #138:

score: 0
Accepted
time: 58ms
memory: 3728kb

input:

9999
abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaababbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaa...

output:

25000000

result:

ok 1 number(s): "25000000"

Test #139:

score: 0
Accepted
time: 308ms
memory: 3668kb

input:

9999
abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcacababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacaba...

output:

11108889

result:

ok 1 number(s): "11108889"

Test #140:

score: 0
Accepted
time: 59ms
memory: 3736kb

input:

9999
acaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacacaacaacacaacacaacaacacaacacaacaacac...

output:

38192400

result:

ok 1 number(s): "38192400"

Test #141:

score: 0
Accepted
time: 57ms
memory: 3672kb

input:

9999
abaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaaba...

output:

41319184

result:

ok 1 number(s): "41319184"

Test #142:

score: 0
Accepted
time: 57ms
memory: 3652kb

input:

9999
abaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaa...

output:

44435556

result:

ok 1 number(s): "44435556"

Test #143:

score: 0
Accepted
time: 59ms
memory: 3676kb

input:

9999
bcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcb...

output:

49980002

result:

ok 1 number(s): "49980002"

Test #144:

score: 0
Accepted
time: 411ms
memory: 3668kb

input:

9999
bbccbbabbbbcabbbaabbbbbcbbbbbababacabaaababbbbabbabbbcccbbbbbccbbaabcbabbbbabbbacaaccabcbcababccaaaabcabcbbbaabbbbbabacacabbacbaccacbaabbbaabacbbaacaaabbcbbcbbccbcbbbbbbccbbaccbbcbacbabcbacbbccbbbabaaccacbacacbbbbbbccaccaabbacabaabbcacabbbaabbacabccbabccbccacbcbbcababbbcaabcccbccbbbbbbabbcbacbc...

output:

24730729

result:

ok 1 number(s): "24730729"

Test #145:

score: 0
Accepted
time: 288ms
memory: 3664kb

input:

9999
bbbbbbbaaaabaabbacbbabbbbcbbbbbbbbbaccbbbbbbbaabbbbacabbbbbabbabcabcbbbbbabbbabbbbbbabbbbabcbbbbbbacbbbbabbababbbcbbbabcabbcbbabbbbbbbcbcacbbcbbacbbbcbbbcbbcabbabbabcbbbbbbbbbbaabbbaabbbaaababbbbbacbbabaababbbbbbbbcaabbbbbbabbbacbbbabbbcbbbababbcbbaabccaabbcbbbababaabbbbbabbbbbbbabbbbbbbabbbaba...

output:

44368921

result:

ok 1 number(s): "44368921"

Test #146:

score: 0
Accepted
time: 59ms
memory: 3696kb

input:

9999
cbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbc...

output:

49980002

result:

ok 1 number(s): "49980002"

Test #147:

score: 0
Accepted
time: 246ms
memory: 3672kb

input:

9999
acabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabacabaca...

output:

25000000

result:

ok 1 number(s): "25000000"

Test #148:

score: 0
Accepted
time: 105ms
memory: 3692kb

input:

9999
aaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaabaaabaaabaaabaaacaaabaaabaaabaaacaaabaaa...

output:

58049161

result:

ok 1 number(s): "58049161"

Test #149:

score: 0
Accepted
time: 192ms
memory: 3652kb

input:

9999
ababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababaca...

output:

28451556

result:

ok 1 number(s): "28451556"

Test #150:

score: 0
Accepted
time: 70ms
memory: 3664kb

input:

9999
aaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaaaaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaaba...

output:

70090384

result:

ok 1 number(s): "70090384"

Test #151:

score: 0
Accepted
time: 4ms
memory: 3644kb

input:

899
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

808201

result:

ok 1 number(s): "808201"

Test #152:

score: 0
Accepted
time: 76ms
memory: 3748kb

input:

9999
aaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaaaaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaa...

output:

77352025

result:

ok 1 number(s): "77352025"

Test #153:

score: 0
Accepted
time: 208ms
memory: 3728kb

input:

9999
abacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacaba...

output:

34023889

result:

ok 1 number(s): "34023889"

Test #154:

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

input:

10000
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

100000000

result:

ok 1 number(s): "100000000"

Test #155:

score: 0
Accepted
time: 71ms
memory: 3676kb

input:

10000
babaaaaabaabbabbaaaabbbbbaaabaaaabbabbbbaabbbaababbaaaaabbbaaabbbbbabaabbabbbabaabaabbababaabbaaaabbbaaabbbbababaaababbaaababaabbaabbbabbababbbabaabbbabbbabbaaabababbabbbbbbababaaaabbabaaababbaaabaaaabaaababbabaaabbaabbabbabbabababaabbbabbbbbabaaaaababababbbbaabaabbabababbabbabbaabababbabababa...

output:

25938649

result:

ok 1 number(s): "25938649"

Test #156:

score: 0
Accepted
time: 447ms
memory: 3684kb

input:

10000
caabbabacaccccacaaaabaccabcbcbcacacaaabaaacccbabacbacbbacabbbbabbcbbccbbcbaccaccccacaacacbcccccbccaacabbbcaaabacbbaabacbabccbbccccabacbcbbaaabbbaabcbbcccbbcbcccbcaacbababcbbcacbaaacbbccbcbbcccabaabbacbbccaaccbbabcabaacbbcccacccbccbabaaaaaccccacccacccccbaaccbcbbcaaabababcbaaabcccbccaacacaaaabca...

output:

11195716

result:

ok 1 number(s): "11195716"

Test #157:

score: 0
Accepted
time: 58ms
memory: 3648kb

input:

10000
abbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbaabbabaabbaababbabaababbaabbabaababbabaabbaababbabaababbaabbabaabbaababbaabbabaababbabaabbaababbabaababbaabbabaababbabaabbaababbaabbaba...

output:

25000000

result:

ok 1 number(s): "25000000"

Test #158:

score: 0
Accepted
time: 308ms
memory: 3612kb

input:

10000
abcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcacababcbcaabcbcacabbcacababcabcbcacabbcacababccababcbcabcacababccababcbcaabcbcacabbcacababccababcbcaabcbcacabcababcbcaabcbcacabbcacab...

output:

11115556

result:

ok 1 number(s): "11115556"

Test #159:

score: 0
Accepted
time: 55ms
memory: 3596kb

input:

10000
caccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccacaccaccacaccacaccaccacaccacaccaccac...

output:

38192400

result:

ok 1 number(s): "38192400"

Test #160:

score: 0
Accepted
time: 57ms
memory: 3672kb

input:

10000
abaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaababaabaabaabaab...

output:

41332041

result:

ok 1 number(s): "41332041"

Test #161:

score: 0
Accepted
time: 57ms
memory: 3604kb

input:

10000
abaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaabaaba...

output:

44448889

result:

ok 1 number(s): "44448889"

Test #162:

score: 0
Accepted
time: 60ms
memory: 3736kb

input:

10000
bcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbcbc...

output:

50000000

result:

ok 1 number(s): "50000000"

Test #163:

score: 0
Accepted
time: 408ms
memory: 3676kb

input:

10000
bacbbbbacababacbcabbbcbcacbbbbaaaabcccbbbaababbaabaacaaccbcbababbabbabbaaaabbcabbbbabcccaacbaacbbabaabccbbbaabcbbbababccbbbaacababbabbbabbbbbabbabbbcbbbbabbbbabbbbabbaccbbcbbbbbbabcbbbcbacbbbbcababbcbbcbabbbababbbacccbcbabbabcbbaacaabccbabbbbbcbbcbabcbccbbcbbcbabcabcbbbacbaccbbabbcabacabbababb...

output:

24920064

result:

ok 1 number(s): "24920064"

Test #164:

score: 0
Accepted
time: 279ms
memory: 3672kb

input:

10000
ccaacccaccccbcaaccacaccccccbcccaabbccacccacccbcbbcaccbbabcbaccacccacbccbbcabccbacccaaabccccacccacabaacbaccccccccaccccaccbccbbcccccccaaaccccaccccacbaaccccccccaccacbccaabcccbcccccccccccccccccccccbccbccccaabbaccccccccacccbccacccaccccccbcacacccbbccccacccabccaccacacccacccacccccbccacccacbaccaccccccc...

output:

45131524

result:

ok 1 number(s): "45131524"

Test #165:

score: 0
Accepted
time: 59ms
memory: 3668kb

input:

10000
ababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababab...

output:

50000000

result:

ok 1 number(s): "50000000"

Test #166:

score: 0
Accepted
time: 246ms
memory: 3620kb

input:

10000
cbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacbcacb...

output:

25000000

result:

ok 1 number(s): "25000000"

Test #167:

score: 0
Accepted
time: 104ms
memory: 3612kb

input:

10000
aaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaaaaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaacaaabaaabaaabaaabaaabaaabaaabaaacaaabaaabaaabaaacaaabaa...

output:

58049161

result:

ok 1 number(s): "58049161"

Test #168:

score: 0
Accepted
time: 192ms
memory: 3600kb

input:

10000
ababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacababaaababacababacababacabababababacababacababacababaaababacababacababacababaaababac...

output:

28451556

result:

ok 1 number(s): "28451556"

Test #169:

score: 0
Accepted
time: 71ms
memory: 3620kb

input:

10000
aaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaaaaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaabaaaaabaaaaabaaaaabaaaaabaaaaacaaaaab...

output:

70107129

result:

ok 1 number(s): "70107129"

Test #170:

score: 0
Accepted
time: 4ms
memory: 3640kb

input:

899
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa...

output:

808201

result:

ok 1 number(s): "808201"

Test #171:

score: 0
Accepted
time: 71ms
memory: 3736kb

input:

10000
aaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaaaaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaaabaaaaaaabaaaaaaacaaaaaa...

output:

77352025

result:

ok 1 number(s): "77352025"

Test #172:

score: 0
Accepted
time: 207ms
memory: 3652kb

input:

10000
abacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacabacabaaabacab...

output:

34023889

result:

ok 1 number(s): "34023889"