QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#601551#8244. Digit TranslationandaheAC ✓10ms20508kbC++171.7kb2024-09-30 06:32:542024-09-30 06:32:55

Judging History

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

  • [2024-09-30 06:32:55]
  • 评测
  • 测评结果:AC
  • 用时:10ms
  • 内存:20508kb
  • [2024-09-30 06:32:54]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define debug(x) cout<<#x<<" "<<x<<endl
const int N(1000005);
const int mod(9302023);
const int SIGMA = 26;
const int M(1000);
struct Automatic
{
	int ch[M][27], cnt, f[M], val[M];
	queue<int>q;
	void insert(string s)
	{
		int Now = 0;
		for(int i = 0; i < s.size(); ++i)
		{
			if(!ch[Now][s[i]-'a']) ch[Now][s[i]-'a'] = ++cnt;
			Now = ch[Now][s[i]-'a'];
		}
		val[Now] = s.size();
	}
	void getfail()
	{
		for(int i = 0; i < SIGMA; ++i) if(ch[0][i]) q.push(ch[0][i]);
		while(!q.empty())
		{
			int x = q.front(); q.pop();
			for(int i = 0; i < SIGMA; ++i)
				if(ch[x][i]) f[ch[x][i]] = ch[f[x]][i], q.push(ch[x][i]);
				else ch[x][i] = ch[f[x]][i];
		}
	}
}AC;
void Insert()
{
	AC.insert("one"); AC.insert("two"); AC.insert("zero");
	AC.insert("three"); AC.insert("four"); AC.insert("five");
	AC.insert("six"); AC.insert("seven"); AC.insert("eight"); AC.insert("nine");
}
char s[N];
ll f[N], g[N];
void Modify(int ff, int gg, int &a, int &b)
{
	if(ff > a) a = ff, b = gg;
	else if(ff == a) b = (b+gg)%mod;
}
void DP()
{
	int len = strlen(s+1), Now = AC.ch[0][s[1]-'a'];
	for(int i = 0; i <= len; ++i) g[i] = 1;
	for(int i = 2; i <= len; ++i)
	{
		Now = AC.ch[Now][s[i]-'a'];
		int k = AC.val[Now];
		if(!k) { f[i] = f[i-1]; g[i] = g[i-1]; }
		else
		{
			int Mx = 0, Mxg = 0;
			Modify(f[i-1], g[i-1], Mx, Mxg);
			Modify(f[i-k]+k-1, g[i-k], Mx, Mxg);
			f[i] = Mx, g[i] = Mxg;

		}
	}
	cout<<len-f[len]<<endl;
	cout<<g[len]<<endl;
}
int main()
{
	//freopen("1.in","r",stdin);
	ios::sync_with_stdio(false);
	cin.tie(NULL);
	cin >> s+1;
	Insert();
	AC.getfail();
	DP();
	return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 0ms
memory: 3844kb

input:

icecreamcone

output:

10
1

result:

ok 2 lines

Test #2:

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

input:

onetwo

output:

2
1

result:

ok 2 lines

Test #3:

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

input:

twone

output:

3
2

result:

ok 2 lines

Test #4:

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

input:

a

output:

1
1

result:

ok 2 lines

Test #5:

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

input:

zero

output:

1
1

result:

ok 2 lines

Test #6:

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

input:

one

output:

1
1

result:

ok 2 lines

Test #7:

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

input:

two

output:

1
1

result:

ok 2 lines

Test #8:

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

input:

three

output:

1
1

result:

ok 2 lines

Test #9:

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

input:

four

output:

1
1

result:

ok 2 lines

Test #10:

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

input:

five

output:

1
1

result:

ok 2 lines

Test #11:

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

input:

six

output:

1
1

result:

ok 2 lines

Test #12:

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

input:

seven

output:

1
1

result:

ok 2 lines

Test #13:

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

input:

eight

output:

1
1

result:

ok 2 lines

Test #14:

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

input:

nine

output:

1
1

result:

ok 2 lines

Test #15:

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

input:

enfzncejemisgzoqnzkgtltxvxybvwddlpsndjyemdcbxyifzjygquvkvbmuhoblihvbxuthwryohdosidsfuzpzgixpkconlbpgscilqqvpblzmwuyrmvwngpnftlcmkjrjsdvgosnnbkldmrrkmucrqyulyxpqehztlssgpmcdsmzylvzaclzgvzaaajsfyyssmthmlaxmudbmmubwdtuifgryoxhorzhjvqxmjcqirlcmvfuttraqyjeztbilbvygakdhxzvyrqcddljjcgzcolvqljabluixyerpevtp...

output:

999618
2

result:

ok 2 lines

Test #16:

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

input:

zerofoureightfourzerofourthreesixfiveonesixoneighteighthreefoursixzeroeighteightzeroneightsevenfourseveneightwoeightwosixninesevenseventwonineightonezerosixonesixsixsixzeroeightsixzerothreefoursevenfourfiveninefiveninetwofouronesevenseventhreesixfoursixfourninesixonesevenzerofourzeroninezeroseveneig...

output:

290113
4873734

result:

ok 2 lines

Test #17:

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

input:

ninethreefivezerotwoeightwofourfourfiveoneonezerosixeighteightonetwonineightoneoneninezeroeightninefoursixtwozeroninefourninefiveonefiveightzeronetwonefivefivesixtwofivezerozerozeroeightoneightfouroneightwoeightfivezerofivezerosixseveninefiveonezerotwofivesixfourzerofourtwofoureightsevenseveneightwo...

output:

289658
3563018

result:

ok 2 lines

Test #18:

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

input:

threefourtwoeightwoeightwosevenoneonesevensixsixeighteighteighthreeightzerothreeoneightonefourseventwozerosixfourthreeninesevenzeroneonesevenfourfournineightsixtwonenineonefoursevensevenfourtwoeighthreethreeonefouroneighteightfourthreeninesixfiveightsevenfivetwonezerothreeightwoseventhreeonesixseven...

output:

290208
2171466

result:

ok 2 lines

Test #19:

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

input:

foursixthreetwoeightsixfourfoursevenfivezeronefourfiveseventwothreetwosevensevensixninefivetwoseveninefivethreeightfiveninetwoeightfivetwotwoeightninesixsixninetwoneightwofivefivesixsevenfourzerofourzerothreeonetwofiveightsixfivesevenzerofourthreeninezerosixtwotwothreefivezerofouronefoursixtwosixzer...

output:

289990
2652587

result:

ok 2 lines

Test #20:

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

input:

onefourfourfivenineninesixfouronezerothreesixninezeroninetwoeightsixzeronefiveninefourfourseventwofourthreesixoneightfiveightzerozerothreetwofivefourtwothreethreeseveninesixonefivezeroeightnineseveneightsixthreeoneseventhreefivesevenzerofivefourthreethreetwosevenfivesixeightwothreefouronesevensixsev...

output:

289863
7390305

result:

ok 2 lines

Test #21:

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

input:

eighthreefivesixzerofivethreezeroeighteightfiveonethreefourzerofouronesixfourfivetwonesixtwofoureightwofivetwofivetwonefivezerosixzerosevenonesixnineoneseventwoeightfivesixtwothreefiveninezeroeightzerothreeseveneightwozeroeightfourfourfoursevensixzerothreeonethreeseveninesevenzerosixninefourtwosixsi...

output:

289885
7220842

result:

ok 2 lines

Test #22:

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

input:

sixfourthreeightsevenoneoneninethreeninesixninetwofoursevenineseveneightsixfivesevenseveninezeronefouroneseventwozerosevenzerosixeightzerofivethreezerofourthreefoureighteighteighthreefouronezerozerotwotwotwonefourthreeightwofournineseventwotwofiveonefiveoneonethreeninefoureightsevensixtwoeightwonesi...

output:

289879
4187175

result:

ok 2 lines

Test #23:

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

input:

sixthreezerofivefiveightfivenineninesixonefiveoneoneoneseventwoeightfivethreetwotwotwoninesixtwozeroeightfoureightfivezeroninesevensevenzerosixeightsevenfourtwofoursevenzerosevenfivetwozerozeroninethreezerotwonezeronesixfivezeronefourtwoneoneonezerofiveoneninethreefivethreeightnineightfoursixoneight...

output:

289764
7008891

result:

ok 2 lines

Test #24:

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

input:

eightfivezeronesixzerosixthreezerosixfourthreesixthreefivefourzerothreesevenineseveneightoneoneninefouronesixeightsevensixfournineseventwozerothreesixninefourzeroneightwoeightzerofoureightnineightninesixzerothreetwosixtwothreeighthreesixsixfivethreethreetwoeightzeroninethreesevenzeroninefivefourthre...

output:

289826
6266873

result:

ok 2 lines

Test #25:

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

input:

fourfourfivezerosixfivezerothreeightfivefourtwonineightzeroneninesixfourfiveoneighteightfivetwofivefiveightseveninezerothreefourfourthreezerofourtwofoursevenfivefourninezerotwonineninenineninethreethreenineninetwonefourfourfourseventhreefourfiveseventhreeoneonesixseveninefiveightzeroninefournineonet...

output:

289658
4845142

result:

ok 2 lines

Test #26:

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

input:

sixonefivefivesixsixsevenfivesixeighthreeninefourseventwozerothreefivesixsevenonethreetwoeightsixtwoeighteightfoureightfiveonesevenzerozerofourninethreethreeninefivefourfivefivethreesevenzerofivesixtwosevenonethreeonesixthreethreenineseventwotwofourninethreethreetwoeightfourthreesevenseveninezerotwo...

output:

290274
7441145

result:

ok 2 lines

Test #27:

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

input:

onethreesixthreezerofourtwoninezerosixeightsixoneoneightfiveoneightninefivesixfourtwofiveonezerosevensevensevenzerosixthreeninetwoninefourtwonineightninefoureightfivefourfiveoneightsevenfoursixtwoninetwozerozeronineightninesevenonezerofoursevenseventwotwoeighteightzerozerosixeightwofivethreefiveight...

output:

290579
2777314

result:

ok 2 lines

Test #28:

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

input:

fourthreefiveninetwosevenfiveoneonefivetwofivenineoneseventwozerosixfivefoureightoneseventwoninenineoneninesevensixfiveonesixthreesevenfourzerotwotwofourthreenineseventhreesevensixthreetwofivefoursixfivesixonenineninefiveonethreezerosevenzerozerozerothreesixfivezerosixfourninezerotwonefivesevenfours...

output:

289971
7148511

result:

ok 2 lines

Test #29:

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

input:

foureightseventwothreezerozerothreesixfouronethreeightfiveighteightwonineighteightwofiveninetwotwonesevenineninefourthreefivefivetwoeighteightsixfiveightonethreesixthreeonesixsixninesixzerosixsevensevenseveneightzerozerofiveightfiveighteightsixzerofoureightfoursixeightwoninefivetwozerosixtwoninenine...

output:

290268
5818981

result:

ok 2 lines

Test #30:

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

input:

twoeightninefivefiveoneninethreeightfourseventhreetwosevenfourfoureightsixfivetwozerotwonesixeighteightwonineightninetwonineseveneightninefiveseventwozerotwonineonesixfourtwosixfourfiveighthreefourninefivethreetwoninesixfourfiveonefourfourfourtwoeightsixsevensixeightoneoneighthreefivefourthreenineni...

output:

290064
6749667

result:

ok 2 lines

Test #31:

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

input:

sevenonethreetwotwonefourtwosixsixfivefourtwozeroseveneightfivezerosixtwoeightfiveoneonezerosixtwothreeseveninefivesixonefoursixninetwofivesixeightsevenineninetwoeightwofiveseventwoeightninesevenfourtwozerosixfourninefoursevenonetwonineninezeroeightfourfivesixonetwosixzerosevensixtwofouroneonethreez...

output:

290231
2817950

result:

ok 2 lines

Test #32:

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

input:

fivezerofiveighthreeninethreefournineightoneightsevensixninesixsixthreezerofoursixninefourseveneightsevenonesixfiveonezerosixeighthreeninetwozerofivetwosixfivesevenfourninethreeninetwozerosixninefivezerosevenonezerothreetwonineonetwozerofourzerosixzerofourseveninesixeightzerofivefiveseveneightfourfi...

output:

289627
6791565

result:

ok 2 lines

Test #33:

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

input:

twoneightfiveightonethreefourzerotwothreeightsixninetwotwosixthreeninefivezerofivethreefoursixfivetwosixsixeightwonefiveoneighteighteightsixoneseventhreesixfoursixfoureightfourthreeninefoursevenfivefouronenineninezerozerofivetwoneninetwosixtwonezerosixsevensixfiveonethreesixsevenfourninesixonefivetw...

output:

289724
7918082

result:

ok 2 lines

Test #34:

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

input:

threetwoeightfourfourfourzerosevenfivefourthreefourtwoninesevenfivefivesixzeroseveneighthreeonesixfiveninesixsixninesevenoneninefourninethreethreezeronefourzeroeightfourfivefourfiveightzerothreeseveninefourtwozeronineightsixninetwofoursevenonetwofoursixoneighteighteightnineseveneighteightseveninethr...

output:

290011
1138256

result:

ok 2 lines

Test #35:

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

input:

sevensixthreeoneightonethreefourseventwonineightfourseveneighteightsevenzerofivethreeonetwosixzeroneightfourfoursixseventhreesixsixninefourthreethreeninenineightzerofivetwosixzerotwotwotwosevenfournineoneninesevenineightsevenseveneighthreetwonetwoeighthreefivesixeightwofoureightzeronefourthreesixone...

output:

290344
4372751

result:

ok 2 lines

Test #36:

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

input:

sevenzerofourfivesevenzeroeightsixseventwozerozerozeroninezerofoureightonethreefivetwozerosixninesixfourtwothreetwofivetwoeightninefouronesixseveneightfourzeronethreesixzerosevensixoneseveninesixsevenonesixonezeroneighthreetwofivetwoseventhreesixsixtwonesixeightfoursixfivesevenonethreeoneonetwofours...

output:

289913
7658526

result:

ok 2 lines

Test #37:

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

input:

seveneighthreeoneseveninetwothreefivezerofivethreeightsevenzerosevensevensevensixonethreeninesevenzerofivetwonetwozerosevensevenfiveightoneighthreesixsixzeronesixoneightwoninetwonefivethreeninetwosixzerofourzerothreethreetwofoureightnineighteightninesixtwothreesixthreetwofoureightsixeightzeroninesev...

output:

289530
5163209

result:

ok 2 lines

Test #38:

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

input:

threeighteighthreesixoneninesixfiveonefourzerozerosevenzerotwosevenzerosixfoursevensixfiveoneninethreeseventhreeighteightsixsixfourfourfoureightsevenfourfourtwofoursevenfoureightfivetwonezerothreesixninesixseveneightfiveightseventhreefourfivefourzerosixzeroninetwoseventhreeightsevensevenonefourthree...

output:

290376
14593

result:

ok 2 lines

Test #39:

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

input:

threefivefourfoursixeightzeronineonezeroneninefourfourfiveightoneoneighteightninethreethreesevenonesixtwoeightwofourfivesixfivefourfivefivefoursixfourfoursixseveneightoneonenineseventhreefourseventwoneonefoursixeighteightzeroseveneightninefournineightwosixfiveonetwotwofourseventhreethreefourninezero...

output:

289503
936238

result:

ok 2 lines

Test #40:

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

input:

eightsixfivetwozeroninesixfouronezerofivezeroeighthreeonesixeightzeroeightfivefourzerothreesixsevensixeightonezerofourfourzerozeroneninethreeightoneseveneightwothreethreeninetwozerosixninetwofiveninefourthreetwofourfivesixfiveoneoneoneonetwotwothreefourzeroeighthreefivesixoneninetwoeightzeronetwones...

output:

290395
7388077

result:

ok 2 lines

Test #41:

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

input:

zerozerothreefiveseventhreefourseveneightninezeroseventhreethreezeronesevensevenonefoureightonezerozeronezerosevenonesixzeroeighthreeoneseveninefivesixsixonefivefoursevensixtwosevensixeighthreenineninesixtwozerothreefivethreeninesevenfivefivezeroninefiveninetwotwozerozeroneninetwothreesixzeronesixfo...

output:

289681
6794261

result:

ok 2 lines

Test #42:

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

input:

eightsixsevenfourfivesixeightonesixzerofoureightwothreeseveneighteightoneonesixsixnineightsevenzerothreeonetwoeightzerofivefoursevenzeroneonetwofivetwosixninefoursevenonefoureightwonethreetwoseveninefivesevenfivefoureightfivefourthreeonefivefoureightsevenzeroneightseventhreezeroeightwoninetwosevenon...

output:

289931
400237

result:

ok 2 lines

Test #43:

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

input:

twothreeninetwosixonefoursixninetwonetwotwosevensixsevensevenfivethreeightonesixsixtwosixsixfourzeroneoneoneightfivesixoneightnineightfoureightsixeighthreefiveninetwoeightsixsixzeroeighthreefoursixfourfoursevenonefivesixsixeightonethreethreethreeightonethreetwosixsevenfourfourtwoninetwotwotwosixsixf...

output:

290079
5351332

result:

ok 2 lines

Test #44:

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

input:

zeroseventhreethreefiveonethreethreefivezerozeroninethreetwoeightsixtwonethreeoneightonethreesixfoursixzerofourfoureightfivethreefourzerosixeighthreefourfourfivethreezerothreetwotwoninethreeninesevenseventhreeninesevenineoneonetwosixninethreeoneonethreeonesevenseventhreethreefourninesixsixeightfours...

output:

289841
4527357

result:

ok 2 lines

Test #45:

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

input:

fouroneightonefoursixzeroeightnineonetwosixthreezeronezerofivethreeightfivesevensixtwozerofiveightsixfivesevenzerotwonefivetwosevensixsevensixseventwoneightninezerozerothreeonetwozerotwoninesevenoneonezerosevenseventhreeseveneightwofivenineightzerosixfourthreeighthreesevenfourfivenineightoneninethre...

output:

289740
6379684

result:

ok 2 lines

Test #46:

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

input:

fiveoneightsevenseventhreenineninesixthreeninenineninefoursixzerosixseveneightfoureightseventwotwosixthreeightoneseveneighteighthreefoursixtwofiveightsevenfournineightsevenzerothreethreeonetwotwoninefourfivezerothreesevenfivetwofourzerofivetwozerozeroninethreefourseveninesevenfoursixzerofivefiveonef...

output:

290269
2386515

result:

ok 2 lines

Test #47:

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

input:

twonefivefivefourfivefourninesixtwotwosevenfiveninenineninefiveonefivefoureightwothreethreetwofourzerofourninefivethreethreesixsevensixninesixfouronezerozerosixzerofourfourfoursixeightsixonezeronethreeightfouronezerofivefoursixfivefivefivefourfivesixthreetwonineonezeronineightfivefiveighthreesixsixn...

output:

290185
4898931

result:

ok 2 lines

Test #48:

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

input:

eightwonineninezeroeightfourfiveninefivezerothreesixzerofournineninetwotwofivefiveninezerosevenonesixsevenfivetwoeighteightonenineseventhreefoureightseventwozeroseventwosevenzeroneighteightsixfourfourtwofiveighthreeightfivetwothreesixoneoneightwoninefivethreezerosixeightsixtwoninethreethreethreethre...

output:

289744
4672872

result:

ok 2 lines

Test #49:

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

input:

fourninethreefourseventhreeonesixzeroneninesixthreesevenfourtwozerothreeseveneighthreezerofourfivesevenonesixtwonezerofourzerosevensixfivezerosevensixthreethreesevenzeronethreefivefouronefiveightnineightsixzerofivezeroeightwosixoneonefourzeroninefivesixninesixtwonineonethreesixzeroninetwoseveninefou...

output:

290294
3893388

result:

ok 2 lines

Test #50:

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

input:

foursixfiveonesevensixfivethreesevenzerozeroeightnineninesevenzeronezeroeightwofoursixtwosixfivesixtwofoursixthreenineightfivefivefivesevenzerosixzerosevenfourthreeighthreeonesevensevenseventwofivefourthreefiveightseveninesevenonesixfourfourfiveseveninetwosevenzerosixfivetwozerofoursixsevensixninesi...

output:

289924
4836785

result:

ok 2 lines

Test #51:

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

input:

fournineninesevensixsevensixzerotwofourzerotwotwoninefivesevensevenseventwozerofourthreefivefivesixthreeonefivesixsevenoneninefiveighteighthreeninetwofourtwofouronesixninefiveightsixthreeonezerothreezeroninethreeoneninesixeightonetwofournineseventhreetwoeightfourfournineightsevenfivefiveseventwothre...

output:

290549
5247542

result:

ok 2 lines

Test #52:

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

input:

twozerotwotwoseveninesixseveneightnineninefivefourthreeonefiveninefourtwofourfourfivethreesevenoneninetwoseventwothreenineightnineoneightseveneightfivefourthreethreezeronesixthreeightzeroseveneightsixonetwosixtwothreetwofivetwofourtwoneseventhreeonefourthreetwotwofourthreetwothreeseventhreesevenonet...

output:

289519
2792710

result:

ok 2 lines

Test #53:

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

input:

onetwofoursixsixsixfivezerozerozerosixnineightfivesixzeroeighteightonefiveseventhreezerosevenfivethreenineightfourfouronezerofoursixtwoeighthreeightoneseveneightninetwosixonethreesixseventwofourzerozerofoursevensevensevenfoureightzerofivefoureightnineninesevenineonefourfivezerofiveightsevenfivefours...

output:

289298
6359163

result:

ok 2 lines

Test #54:

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

input:

twofivesevenfiveoneightnineninezerothreetwoneighteightonesevensixfourfivetwoninefiveninezerofivefouronefoursixfiveonefourzeroneonezerofourfiveninezerotwonezeroeighthreenineseveneightnineighteighthreeninefoursixnineoneoneninetwoeightfourfivefiveonefourthreezerotwonineninethreezerotwoeightfourfournine...

output:

289740
5290277

result:

ok 2 lines

Test #55:

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

input:

twothreetwosevenzerothreeightoneightsevenfoursixzerosixsixfourfouronethreesixfivesixonenineonefivefourfiveonefoureightnineonetwosevensevenoneninezerozeroeighteightzerothreethreenineonesixfourzerofivefoureightnineightsevenfivesixsevensevensixnineninezeronineonesixonefourthreeonefourthreefourseveninen...

output:

289656
4730849

result:

ok 2 lines

Test #56:

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

input:

nineninetwozerozeroninefivezerofivezeroseveneightzerothreethreeightnineseveneightzerotwoseveneightzeroninezerofivezerothreenineninefivesixeightnineightwofourfiveonesixzerothreethreeoneonesevenfourfourfiveseventhreeseventhreesixsixzerothreeonesevenzerofivefourfivefiveninefourtwoninethreezerothreefour...

output:

290686
1451387

result:

ok 2 lines

Test #57:

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

input:

fivenineonezeronethreeightwoneoneoneninesixfiveightsixeightwozerozerothreezerothreeseveninefivethreesevensixonesixninefouronethreesevensixnineseveninethreeseveninefiveonetwothreezeronefivefouronezerotwoeightfivesixonethreezeroneninezerotwonethreefourfourtwosevensixfivetwotwofivefoureightfiveseveneig...

output:

290244
109563

result:

ok 2 lines

Test #58:

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

input:

seveninetwofivesevenineightninetwofoursixeightsixnineightfivefourzeroninenineighthreesevenfivesixoneightwosevensixfiveonefoureightsevensevenzerofouronethreefivesevenonetwofivesixthreefouronenineoneninefoureightseveneighteighteighthreeonesixsixzerofourfivethreesevenfourtwotwosixseveneightfiveoneseven...

output:

290089
7680855

result:

ok 2 lines

Test #59:

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

input:

fivezerofivefiveoneightsixzerozeronesixoneightwofivezerotwothreezeroeighthreeonezerotwofourzerofivetwofivesixeightfourtwonefivenineonefivetwosevenseveneightzerosixfiveonezerosevenzerofivesixeightonefourfourzeroninezerothreeonefoursevenoneightsevenfivesevenoneoneseventwosixsixsixonetwosevensevenfives...

output:

289941
2189238

result:

ok 2 lines

Test #60:

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

input:

eighthreesixfourninethreeoneightwotwonetwothreeninethreesevenonefivesevenfourzerosixseventhreesixthreesixeightsevensixonenineseventwotwoseveneightfivesixsixninenineninefivesixfiveonezeronineoneseveneightonetwozerosevensixsixeightoneightfivesevenonefivethreefourfourfiveninetwoseveneightsixninesixthre...

output:

290653
821533

result:

ok 2 lines

Test #61:

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

input:

threefiveninetwonineonesixsixeightfiveoneonesevenfourfivezeronefivesevensixsevenzerozeroninesixthreezerozeroeightzerothreethreetwotwoeighteightfourseventhreesixfiveightonesevenfivethreeightoneninezeroninesixsixsevenonefivethreeseveneightsixeightninezerozerozerozeroneseveneightfourzerothreesevenonesi...

output:

290036
5247497

result:

ok 2 lines

Test #62:

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

input:

sevensixfiveoneninesixonethreesixzeroneightzeronezerotwofoursevensixfoureightfiveseveneighthreezeroseveneightzerofourfivefoursevenzerothreesixfourfivezerozerofivezerozeronethreeonetwoeightzeronetwoeightzerosixzerotwothreesixtwofiveonezeroeightonenineighteighteighthreesevensixtwofiveseventhreesixseve...

output:

289710
7504788

result:

ok 2 lines

Test #63:

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

input:

nineightsixeightfourfourtwonineightseveneightsixfourtwozeroneonezerofourfourthreeightfivethreefourthreeoneightsevenseveneightwosevenoneightzerosixsixtwothreefivethreesixthreethreeoneoneseventhreezerothreeonesixnineoneightwotwosixeightwofourfourninesixthreefouronesixeightnineninefourthreefourzeroneni...

output:

290015
1128282

result:

ok 2 lines

Test #64:

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

input:

foursevenzeroseventwothreefiveoneninesixninethreethreesevenfiveightwofoursevenfivezerofourzerozerosevensixfourfourthreetwotwoeightsixzeronineonesixzerosevensixzerosevenzerosevenoneightzeronefourzerofivesixtwonethreesevenoneninethreeseventwofivesevenfiveoneonetwothreeninesevenzerothreeninetwosixeight...

output:

289805
6400707

result:

ok 2 lines

Test #65:

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

input:

sixsixonefoursevensixtwothreefivezeroeightzerotwotwoeightninefourthreezerofivesevenfivethreezerotwosixninefourfivefourfivesixzeroninezeronineightfourninesevenfourseveninethreezeronetwosevenineninesevensevensixfivefivesevenfivetwonineonetwonesevensixsixzeroeightzerofivezeroninesixsevensixoneoneightse...

output:

290018
1340294

result:

ok 2 lines

Test #66:

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

input:

fiveseveneightzerofoureightnineseventhreefivezerothreefivenineightsixthreeninetwosevenfourtwofoureighteightsixsevensixonetwotwozeronezerotwofourthreetwofouronezeroeighthreeninetwotwotwonefourthreeightsixzerotwosixthreezeroseventhreetwoninesevenonetwothreezerotwofiveightonesixfouronesevenzerosevensix...

output:

290070
2623771

result:

ok 2 lines

Test #67:

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

input:

fiveightfournineoneighthreesevenzerofoursixeightwofiveoneonethreetwozeronefiveightzeronesixzerosevenonefourtwoseventwozerozerofiveightfoursevenzerosixonesixsevenineonefourzeroeightninezeronesixeighteightzerozeroeightonefivethreesevenfournineninetwotwonesixeightsixonefiveighthreeninenineninezerosixni...

output:

290032
4913257

result:

ok 2 lines

Test #68:

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

input:

ninezerothreeighthreesevenfivethreeightzeronineightfivefiveninesevenonefivesevenoneightzerozerosixfiveighteightsevenseveneighthreesixsevenonefivefivethreeonefourninefouroneightfourseveninefoureightseventwoninezeronesevenfoursixfourtwonesixfiveonetwothreefourfivetwozerothreesixfouronesixzerosixfivesi...

output:

289779
9099377

result:

ok 2 lines

Test #69:

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

input:

zeronetwozeroeightfourninefivefivethreesixeightnineoneightninethreefourzeronefiveightnineightninesixonefoursevenfoureightzerozeroninefourfiveninethreeightfourfourzerofiveonetwotwonezerofournineseveninenineightfivezerosixthreeighteighthreesixfivefivezeroeightsixnineninethreefivefiveonethreefivesixthr...

output:

289470
4711330

result:

ok 2 lines

Test #70:

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

input:

oneonezeroeightseveninesixfiveightonesixfourninefivesevenseveneighthreethreeonesixninefivenineoneninesevenzeroeightsevensevenzeronezeronineonefourzerosixtwofivethreesixfourtwoninesixthreeightsixzeronefiveonefiveightoneightzerofoureightwotwothreesixsevensevenfivefivezerotwonineonesixtwosixsixzeronefi...

output:

290168
1603062

result:

ok 2 lines

Test #71:

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

input:

onetwoeightonefivesevenonethreezerozeroeightoneightoneninefourtwoninefiveseventhreetwofourthreetwoninesixfourfourfiveninezerozerofivefiveoneonezeronesixfivezeronefiveoneightseventwozeroeightsevensevenonezerothreefoureightfivefivethreefoursixzerozerotwofourzerofivefourtwozerofourninesixsixoneightonet...

output:

290045
5525120

result:

ok 2 lines

Test #72:

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

input:

zerozerothreezerozerofourfourzeroninenineightninenineseveneightsixninefivetwoneonefivetwozerotwoninefivesixthreezeronefiveninesixfourtwofiveighthreenineninethreeightzerothreezeroeighteightonesixfiveoneonefoureightfivetwoeighthreeonezeroninethreefivetwotwofourzeroneonetwosevensevensixtwosixeighteight...

output:

289974
8871908

result:

ok 2 lines

Test #73:

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

input:

oneoneightzerofivesevenzerothreesixtwothreethreeninetwonesixzerofourtwosixninethreefivefivefourthreesixthreesevensixsevenineseveninenineightzerofivesixfivefoureightfourthreesixseveneightzeroeightsevensixfourfourfoureightnineonefivezeroninethreefourtwoninezerotwoeighteighthreeseveneighthreethreeseven...

output:

289869
1138802

result:

ok 2 lines

Test #74:

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

input:

sixsixfiveightonethreeighthreesixthreefivethreefiveninesixzerosevenineighthreesixoneightfoursevenonefivesevenonezerothreesixeighteightzerozerozeroeightwonezeroninefiveonezeroeightwosixzeroneninefiveninesixsevensevenineonethreeonezerothreetwoseveneightsixsevensevenoneonesevenfoursevenineninethreeight...

output:

289837
6826591

result:

ok 2 lines

Test #75:

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

input:

onefoursevenzerotwosixfourfiveoneonesevensevenseveneightfivetwonineseventwotwotwothreefiveonefiveninezerotwofourtwothreezerozerozerothreeighteightzerofoursixtwothreeonefourthreethreethreefourfoursixeightonethreenineighthreesevenfourfourfivethreesevenineightsixthreeninetwozerozerozerozerofiveninethre...

output:

290518
4652912

result:

ok 2 lines

Test #76:

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

input:

eightfiveninezerotwozerosixtwonefourfivenineonezerozeroseveneightsevenfivetwoeightfoureightseventhreesevenineightseveneightzerothreethreesixninefivethreesevenfourninethreetwosixoneoneninefourtwothreefourthreefourninethreeonefivetwosixtwotwotwosixfourseveneightfivesevenzerofourtwozeroninefoureighteig...

output:

290319
8833503

result:

ok 2 lines

Test #77:

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

input:

sevensevenfourninethreetwofiveonezeroninetwothreefourtwosixtwonezerosixfourfivefivezerofivefiveninefiveightonezeronenineighthreetwothreeninetwozeroninesixsevenfouronezeroeightfivesixsevenzerosixfoureighteightsixeightzerozerosevensixoneninetwosixzerofourfiveonetwosevensevensixfoureightnineightninefou...

output:

290365
2149439

result:

ok 2 lines

Test #78:

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

input:

eighthreezerofouroneoneninesixtwotwoseventwosevenzeroninefivethreezeroneninetwoseveneightfourfivefiveonefivesevenseveninesevenzerofoursixsixzerothreethreenineninetwonesevensevenineninetwoninefouroneightsixtwoseventwoninetwotwosevensixsixonefivetwothreesixsevensixtwoninezerozerosevensevenfivefourthre...

output:

289991
3181256

result:

ok 2 lines

Test #79:

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

input:

sevenfiveseveninesixthreeightsixsixfoursixeighthreefoursixfoureightwoninesixfivefourninesixzerotwofivesixsevenfourtwofiveightzerozerothreetwofivesevensixfiveonefourfourfiveightseveneightseventwoeighteightonesevensevenfourthreefivezerofoursixeighteighthreesixfivesixeightfivethreesevenfivetwothreeonet...

output:

290013
6208106

result:

ok 2 lines

Test #80:

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

input:

fivefivefivetwofiveoneightonesixtwoneseventhreetwothreefiveightsixthreethreesixsixthreesixfivethreeoneseveninesixzerofivefivesixthreesixfivefiveonesixsixtwotwonineonesevenzerofivesixfourthreefivesixtwofivefoursevenineighthreethreefiveonefourtwoninezerotwofivenineonefivethreefivezeroninesixsixsevenfo...

output:

290027
1034094

result:

ok 2 lines

Test #81:

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

input:

seventhreetwofourninezeroninefiveightninethreezerothreeightfoureightonetwofourthreezerofivezeroeightfivefoursixeightfouroneoneninefivetwosevensixfourseveninetwofourthreesixthreesevenineseveneighthreeninethreetwoeightfourzeroeightninezerosevenzerofivetwofoursixeighthreefournineighthreetwozeroneoneigh...

output:

289882
5814344

result:

ok 2 lines

Test #82:

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

input:

seveninesevensixsixthreesixsevenzerosixeightwozerotwosixtwoeighthreesevenfivetwonineonenineightsixsixeightwotwofourtwosixsixsixnineightsevenseventwosixfivethreefivetwozeroeightsevenzerosixfivesixeightzerothreenineighteightwozerothreeninefivefivezerosevenzerofiveninetwofivefoursixsixonefivetwofivesix...

output:

290371
4715759

result:

ok 2 lines

Test #83:

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

input:

sixfoursevenineonefourfiveightwoseventhreesixsixeightwothreeonetwofoursixtwozerofourfourfourfouroneseveninetwotwoeighteightfourfourfivenineightsixsixsixninesixzerofoureightfourfourthreesevenzeroeightfourzeroeightzeroseveninenineninezeronesevenfivefouronefiveseventwosixoneonesixfoureightwotwoneightfi...

output:

289821
4085630

result:

ok 2 lines

Test #84:

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

input:

threethreefivethreefourzerosixsixeightfiveninezerofiveightwofournineonetwofivesixnineonefoursixzeroseventwosixonefourfourfouronetwonineonezerofiveightonefouronethreefourtwofouronezerothreefoursixonethreezerosevenonetwotwonezerothreeninethreenineninethreesixsixsevenfourzeronineonethreeightsixeightnin...

output:

290583
7804066

result:

ok 2 lines

Test #85:

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

input:

threezerofouronefoureighteightoneightzeronesixthreesixtwofourtwozerofoursixfourthreeightfivesixfourfiveninesevensevenineightzerothreesixfiveighthreeninefourfourninesevenfoursixthreethreesixthreezeroseventwoeightnineoneightonetwothreesevenfivesevenfouronefourthreetwonenineonetwozeronethreesixninethre...

output:

289931
7761555

result:

ok 2 lines

Test #86:

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

input:

eightsixninefoursevenzerofournineonefiveightonefourfivefourfiveonetwothreezeronefourthreetwoeighthreethreefivefivezerosixonethreeightfivezerosixsixsixfoursevenfouronenineseveninefoureightsixtwoeightwothreefourfiveonefiveninesevensixseventhreenineninetwofiveightoneightwoeightninethreefivezeronineonez...

output:

290087
7008240

result:

ok 2 lines

Test #87:

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

input:

twosixfiveninesevenfivefiveonefouronesixeightzerothreetwoninefoureightsevenfivetwoeightfourthreeighthreezerosixeighthreetwozeroninesevenzerozeroninesevenfourthreezerosixeightseveneightwoeightsevenonefivesevenfivefournineseveneightsevensevenseveneightzerosevenfiveninefiveninezerosixzerothreetwothreet...

output:

289919
8436049

result:

ok 2 lines

Test #88:

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

input:

nineonesevenfoursixtwonesixfoursixfivesixseventhreefoureightwonineightsevenoneonefourfivefivethreeightninesixzerofivesixeightninesevenzeroneightsixonethreenineonetwosevenfiveoneightwofourthreezerosixnineonesixninesixfourfourtwoeightfourfourzerozerosixzerofiveninethreefourzeroninethreetwosevenseventw...

output:

289884
1509938

result:

ok 2 lines

Test #89:

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

input:

oneightseventwofourtwozeroeightnineighthreethreeonesevensevenzeroeightonesevensixthreefoursixeightonezeroeightseveneighteightsevenfourtwozerofivesixsevensevenoneightsevenonezerozerosevensixthreefivefiveninetwofoureightnineonesixsixnineonesixeightsixfourfivetwoeighthreefivesixnineoneninesevenseventwo...

output:

289763
4421422

result:

ok 2 lines

Test #90:

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

input:

twosevenonethreethreeightsevenfivetwozerofouronesixseveneighteighteighteightzerofiveonenineoneoneightzeroninethreefivesixzeroneninethreesevenzerosevensixfourfoureighthreeonesevenfourfivetwoeightsixthreethreefourzerothreenineninezerotwoninezerosevenzerozeronineoneightsixsixfiveightzeroeightonethreesi...

output:

289887
2703939

result:

ok 2 lines

Test #91:

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

input:

zeroeightzerofourninesixseventwoninefoureighthreesixfourtwoeightsevenzeronethreefoureightoneseveneightwosixfivetwotwotwoeightzeroninetwotwozerothreezerofourzerozeronineonesevenineoneninefourzerofivesevenfourninefivetwoeighteightzeroninefourzerofourfiveseveneightzerothreesixonezerothreeonefivetwotwos...

output:

289860
6008019

result:

ok 2 lines

Test #92:

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

input:

fiveightninezerotwotwonenineightseventwonenineonesevenfivethreeoneninetwoeightonezeronineninefiveightwoseveneightseventhreeninesixthreetwofiveightwoninezerozeroeightsevenfourtwonetwoseventwofivesixthreezeronefourfourfiveseventwoseveninezeroeightoneighthreeightfoursixfoursixsixninezeronineightfourzer...

output:

290317
5095239

result:

ok 2 lines

Test #93:

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

input:

nineightninetwonethreetwotwonineighthreeightnineninethreeseventhreeninezeroneonefivesevenfiveonesixninesixoneonenineninefourtwosixeightonesixeightfourzeroneonesevenineighteightzerosevensevenineseventwoeightfivezerothreetwoseventhreethreefivethreezerozerofoursixfourninetwothreefiveonesixfoursixfourtw...

output:

290078
8093474

result:

ok 2 lines

Test #94:

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

input:

sevenzerofourninethreesixninethreethreefivesixonenineninethreefouronesixtwoeighteightwotwoeighteightzerofoureightfourthreezerofournineonesevenzeroeightsixfouronezerothreenineightwoeightfoureightseventhreefoursevenfiveightsixsixzeroninetwosixninethreeseventhreeninetwotwofourtwotwothreesevenineightfiv...

output:

290488
5160694

result:

ok 2 lines

Test #95:

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

input:

ninesixninetwosevenonezerosevenfoursevenzerofoursixsixthreesixseveninesevensixsixtwofivesixfivefoursixfournineightzerothreefivetwosixfourthreeonethreeightsixsixoneighteighthreethreeonefiveonetwofivefourninefourthreezerozerotwosixtwonineightsixfourzeroeightsevenfivetwothreetwosixeightsevenonetwofiven...

output:

290078
6816404

result:

ok 2 lines

Test #96:

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

input:

ninesixnineoneighteightwotwosevensixfouronetwoninefourfourfivethreezeroninethreesixsevenseventwothreesixtwothreeonefivesixnineninesevensixzerotwoseventhreeonetwozerofourninesixthreeninezerosixzeroeightzerothreeoneightninetwoeightzeronezerofourfoursixsixsixnineninetwotwothreeonezerofourzeronineninefo...

output:

290179
21801

result:

ok 2 lines

Test #97:

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

input:

fiveighteighthreeninesixtwofivezeroninetwoeighteightfivetwozerofoureightfivethreeoneninesevensixnineseventhreeseveninefivesevenonesixtwofoursixonefourtwosevenfourfourninesixfivefoursevensevensevensixsevenseventwozeroseveneightwoeightwothreethreesixeighthreesixzerothreeightonefiveninefourfivesixnines...

output:

290246
729425

result:

ok 2 lines

Test #98:

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

input:

seveninetwozeroeighthreetwoeightzerozerozerosixzerosixsevenonesixsixfivefivethreetwosevensixfourtwoneoneightfourfoureightoneightsixfivetwofourfourthreesevenonefourninesevenfivetwoeighthreefourtwozerofivezerothreezerosixsixonethreetwozeronezerothreesixzerofourzerosixfivenineoneightninefourninefourfiv...

output:

289897
3112848

result:

ok 2 lines

Test #99:

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

input:

seventwofivethreeninethreeighteightninethreesixseveneightfiveightsixthreethreethreeoneightseventwothreeonesevenonefourfivefiveightwofivezerofiveightsevenonefivethreeonethreesevenoneseveneighthreeninefivenineighthreetwonesixthreethreeninetwofoursixfiveninezerothreeoneightnineninenineonesixthreethreeo...

output:

290131
8881323

result:

ok 2 lines

Test #100:

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

input:

threesixfourfivefivenineoneightzeroeighteighteightsevenineightninefoursevenfivesevenfoursixseventwoseventhreeonesevensixsixninetwotwotwozerofiveightfouronefournineninetwonethreesixninethreetwozerofiveightfivetwoninezerothreesevenzeronethreeighteightsixfivethreeonethreesevenfoursixsixzeroninefivezero...

output:

290168
7100477

result:

ok 2 lines

Test #101:

score: 0
Accepted
time: 10ms
memory: 20176kb

input:

sevenfiveninethreezeronineonethreeonethreeighthreezerofiveonesevenonethreefourfivefiveonefoureighteightsixonezeronineninethreethreeightfivefourninefivezerozerothreesixthreetwoeighthreenineighthreeightzeroseventwofiveseveneightwosixthreesixonesixfouronesixeightsevenfouronetwosixfourfivenineonezerothr...

output:

289866
5634888

result:

ok 2 lines

Test #102:

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

input:

sixthreeighthreesevensixeightseveneightsixsixsixsixeighthreesixonefiveninesevenfivenineonesevenfivezerofivefoursevenseveneightsevenoneonenineightfoursixfivezerothreefiveightsevensixfivefourthreeoneninefoursixsevenfivesixfourthreezeroneightfiveightzerothreetwofiveseveninezerosixeightfoureightwothreei...

output:

289486
200906

result:

ok 2 lines

Test #103:

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

input:

fourtwofoursixtwosixoneonezeroeightseventhreeightsixthreeightnineninetwosixsixfivetwonefivefourthreeonefourthreeighthreenineoneonesixninenineightfivezerothreethreethreezerothreeninetwozerosixfourfoursevenfoursixzeroneonenineightzerotwoeightseveninenineightoneightsevensixthreeightwoeightsevenfoursixt...

output:

290254
6007236

result:

ok 2 lines