QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#152213#6355. 5275307894aAC ✓3974ms41760kbC++141.8kb2023-08-27 19:00:132023-08-27 19:00:16

Judging History

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

  • [2023-08-27 19:00:16]
  • 评测
  • 测评结果:AC
  • 用时:3974ms
  • 内存:41760kb
  • [2023-08-27 19:00:13]
  • 提交

answer

#include<bits/stdc++.h>
#define Gc() getchar() 
#define Me(x,y) memset(x,y,sizeof(x))
#define Mc(x,y) memcpy(x,y,sizeof(x))
#define d(x,y) ((m)*(x-1)+(y))
#define R(n) (rnd()%(n)+1)
#define Pc(x) putchar(x)
#define LB lower_bound
#define UB upper_bound
#define fi first
#define se second
using namespace std;using ll=long long;using db=double;using lb=long db;using ui=unsigned;using ull=unsigned long long;using pii=pair<int,int>;using LL=__int128;
const int N=4e5+5,M=2e6+5,K=(1<<15)+5,mod=998244353,Mod=mod-1;const db eps=1e-9;const ll INF=1e18+7;mt19937 rnd(time(0));
int n,m,k,A[N],B[N],siz[N];
vector<int> f[N],ff[N];
multiset<int> g;
int l,r;
void Solve(){
	int i,j,h;scanf("%d%d",&n,&m);
	for(i=1;i<=n;i++) scanf("%d",&A[i]),siz[A[i]]++;
	k=siz[1];
	l=-siz[0];r=m-n+siz[0];
	f[-l+1].emplace_back(0);
	auto work=[&i](int ba,int h){
		ff[h]=f[h];
		for(int p:ff[h]) g.emplace(p-ba);
		if(ba>=siz[i]+1){
			for(int p:ff[h-(i-1)*(siz[i]+1)]) g.erase(g.LB(p-(ba-siz[i]-1)));
		}
		f[h].clear();
		int x=-1e9+7;
		while(1){
			auto p=g.LB(x+k+2);
			if(p!=g.begin()){
				auto q=p;q--;
				if(*q>x) {x=*q;f[h].emplace_back(x+ba);continue;} 
			}
			if(p==g.end()) break;
			x=*p;f[h].emplace_back(x+ba);
		}
	};
	for(i=m;~i;i--)if(i^1&&siz[i]){
		if(!i){
			g.clear();
			for(j=r-l+1;j;j--){
				int ba=r-l+1-j;
				work(ba,j);
			}
		}else{
			for(j=0;j<i-1;j++){
				g.clear();
				for(h=j;h<=r-l+1;h+=i-1){
					int ba=(h-j)/(i-1);
					work(ba,h);
				}
			}
		}
	}
	ll ans=0;
	for(int i=1;i<=r-l+1;i++){
		f[i].emplace_back(1e9+7);
		for(int j=0;j<f[i].size()-1;j++) ans+=min(f[i][j+1]-f[i][j],k+1);
	}
	printf("%lld\n",ans);
}
int main(){
	int t;
	// scanf("%d",&t);
	t=1;
	while(t--) Solve();
	cerr<<clock()*1.0/CLOCKS_PER_SEC<<'\n';
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

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

input:

7 9
0 0 0 1 1 2 5

output:

42

result:

ok 1 number(s): "42"

Test #2:

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

input:

10 33
9 9 8 1 1 1 1 1 1 1

output:

48

result:

ok 1 number(s): "48"

Test #3:

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

input:

10 14
2 4 4 1 0 1 0 1 0 1

output:

81

result:

ok 1 number(s): "81"

Test #4:

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

input:

10 14
3 5 3 0 1 0 1 0 1 0

output:

87

result:

ok 1 number(s): "87"

Test #5:

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

input:

40 50
1 1 1 1 3 3 0 3 1 1 0 0 2 1 0 0 1 0 0 2 7 1 2 1 3 0 2 2 3 1 1 0 0 2 0 1 1 0 1 1

output:

1067

result:

ok 1 number(s): "1067"

Test #6:

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

input:

1200 1000
1 1 2 3 0 1 0 0 1 1 0 2 3 0 1 2 0 0 1 0 4 1 1 2 1 1 0 0 1 1 0 1 0 0 1 0 1 0 0 0 1 1 0 1 0 0 1 0 0 1 1 0 1 2 0 4 0 3 1 6 0 1 1 0 0 0 0 4 0 0 0 0 0 0 1 0 0 1 7 1 1 1 0 1 0 1 0 1 1 0 0 1 1 1 3 0 1 0 1 0 0 1 1 2 2 0 1 1 0 0 1 4 1 2 0 0 0 3 0 0 2 1 0 2 0 0 0 1 1 0 0 2 0 0 0 0 1 1 0 1 0 1 6 1 1 ...

output:

737899

result:

ok 1 number(s): "737899"

Test #7:

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

input:

12000 10000
1 1 0 0 1 0 2 1 3 0 0 1 0 3 1 1 0 1 1 1 1 1 2 1 0 1 2 1 0 1 2 0 5 1 1 1 0 2 0 1 0 1 0 3 2 0 1 0 1 1 2 1 0 0 1 1 0 1 0 0 0 1 0 1 0 1 0 4 0 1 3 1 0 0 1 0 1 2 1 0 0 1 1 0 2 1 1 0 1 0 1 0 0 2 1 1 3 0 1 1 1 0 0 0 1 1 1 0 3 0 0 0 2 0 0 0 1 0 2 0 1 1 1 0 0 1 0 1 0 2 0 0 0 0 0 0 0 1 0 1 0 0 4 1 ...

output:

73685347

result:

ok 1 number(s): "73685347"

Test #8:

score: 0
Accepted
time: 18ms
memory: 27032kb

input:

36000 30000
0 3 4 1 2 1 1 0 0 1 1 0 1 0 2 1 0 0 0 0 2 1 0 2 0 0 0 0 0 1 1 4 1 4 0 0 2 0 0 0 1 1 0 0 1 1 0 1 0 0 0 0 1 1 0 3 1 1 1 0 0 0 0 0 0 1 2 0 2 3 0 0 0 0 3 1 0 0 0 1 0 1 2 0 0 2 0 1 0 0 2 1 1 0 3 1 6 0 0 1 1 2 0 1 2 0 0 1 0 1 1 0 0 1 0 0 0 1 0 2 0 1 1 1 0 0 5 2 0 5 1 0 0 0 0 1 1 1 8 0 1 1 0 1 ...

output:

658813003

result:

ok 1 number(s): "658813003"

Test #9:

score: 0
Accepted
time: 142ms
memory: 39224kb

input:

200000 200000
0 1 1 1 1 1 0 1 0 3 1 0 0 1 1 0 1 1 1 2 3 0 1 0 1 0 2 5 0 1 1 4 1 1 0 0 0 0 0 0 2 1 0 0 2 1 1 2 0 3 0 1 3 0 1 1 1 0 1 0 1 2 0 1 1 0 0 2 2 1 0 1 1 2 4 1 0 2 0 5 1 2 0 0 1 0 2 3 1 0 1 1 1 1 0 0 0 5 1 0 0 1 2 1 1 0 0 0 1 0 0 1 2 1 0 0 2 1 2 3 0 0 3 1 0 1 0 0 1 1 1 0 1 0 1 0 0 1 0 0 1 1 1 ...

output:

23477878007

result:

ok 1 number(s): "23477878007"

Test #10:

score: 0
Accepted
time: 188ms
memory: 34176kb

input:

140000 200000
0 1 3 0 0 0 0 0 1 1 1 1 4 1 1 8 1 1 0 3 0 0 0 1 5 0 1 1 0 4 1 0 2 1 0 0 1 1 1 0 2 4 0 2 0 3 0 2 1 2 1 2 1 1 1 2 1 0 0 1 1 1 1 0 1 0 9 1 5 1 1 4 0 1 1 4 1 1 1 1 3 1 1 1 1 4 1 1 0 3 1 0 1 3 1 1 3 1 1 3 4 1 1 0 0 1 1 0 1 4 1 1 1 1 0 1 1 0 0 2 0 6 5 1 1 3 2 4 0 1 4 1 1 1 1 2 0 0 2 1 5 1 1 ...

output:

15405328745

result:

ok 1 number(s): "15405328745"

Test #11:

score: 0
Accepted
time: 302ms
memory: 34108kb

input:

90000 200000
3 1 1 1 4 5 1 1 1 1 10 1 3 2 1 1 7 8 1 1 8 5 1 1 6 1 1 1 0 1 4 5 0 5 1 21 1 4 0 2 4 3 1 6 7 3 1 1 1 0 1 2 5 1 1 1 1 2 0 8 0 1 2 4 0 0 11 1 2 2 2 1 28 0 1 1 2 1 2 1 11 1 5 9 1 1 1 1 1 2 1 1 1 1 2 1 0 4 1 1 2 1 1 1 4 1 5 1 1 5 4 1 5 1 0 1 1 1 1 0 1 2 4 1 1 1 1 1 1 1 1 1 2 1 1 3 1 2 1 1 0 ...

output:

9895248405

result:

ok 1 number(s): "9895248405"

Test #12:

score: 0
Accepted
time: 366ms
memory: 34968kb

input:

80000 200000
1 5 1 1 1 3 1 0 3 11 1 5 1 2 1 21 4 13 1 1 1 1 0 1 1 1 2 1 13 2 1 4 5 0 1 1 6 3 1 1 1 1 1 1 8 1 1 6 3 1 1 1 1 8 1 2 0 1 1 1 1 1 1 1 17 1 1 1 6 1 1 1 11 1 15 5 1 1 1 1 1 2 8 0 0 1 1 2 3 14 1 1 3 18 1 1 1 3 1 1 1 1 1 1 4 0 9 1 0 1 1 1 0 4 1 2 1 1 3 2 3 21 3 2 11 1 1 0 1 29 1 1 2 1 5 6 1 5...

output:

8980751457

result:

ok 1 number(s): "8980751457"

Test #13:

score: 0
Accepted
time: 480ms
memory: 32860kb

input:

70000 200000
4 0 0 2 5 1 0 1 4 1 1 1 1 3 12 1 1 1 0 1 1 6 5 1 1 1 1 1 0 1 1 1 16 1 1 1 1 1 10 1 2 1 1 0 1 7 1 0 3 3 1 1 1 1 2 2 1 1 7 1 1 2 1 1 1 1 14 1 6 1 1 12 1 1 1 1 1 1 1 7 1 1 1 7 1 1 1 1 2 1 0 1 13 1 0 1 1 1 3 1 3 1 0 1 4 1 1 1 1 3 1 13 0 1 1 7 0 0 1 1 12 3 1 1 3 1 1 1 6 1 1 1 1 1 1 1 1 10 1 ...

output:

8196878191

result:

ok 1 number(s): "8196878191"

Test #14:

score: 0
Accepted
time: 676ms
memory: 35236kb

input:

60000 200000
1 1 1 1 25 1 4 1 1 1 1 1 10 2 12 1 1 1 1 1 12 7 3 1 3 1 1 1 1 1 1 1 1 1 1 1 1 2 1 12 1 1 1 1 0 1 1 3 1 6 1 6 1 1 2 29 1 0 1 13 3 1 1 0 1 1 5 3 1 1 1 1 1 1 7 1 0 9 1 7 1 1 12 4 1 1 1 23 1 4 24 1 36 1 23 1 18 29 1 1 11 1 1 1 1 1 1 0 1 1 2 13 1 32 1 3 1 0 1 1 1 1 5 23 9 1 1 1 8 12 14 1 1 1...

output:

7466221263

result:

ok 1 number(s): "7466221263"

Test #15:

score: 0
Accepted
time: 1202ms
memory: 34612kb

input:

50000 200000
1 1 87 20 1 1 1 1 1 1 1 1 41 1 1 10 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 5 1 1 1 1 1 1 1 17 1 1 1 1 1 14 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 3 1 1 1 1 17 18 1 1 1 1 1 13 1 1 1 1 1 32 1 1 7 1 10 1 1 1 1 14 20 1 1 1 1 1 3 23 27 1 1 1 9 1 1 1 1 4 8 1 12 1 1 1 53 1 1 1 1 26 1 1 1 1 1 1 1 1 1 1 1...

output:

6870036861

result:

ok 1 number(s): "6870036861"

Test #16:

score: 0
Accepted
time: 1977ms
memory: 35084kb

input:

45000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 11 1 1 1 1 1 1 1 1 1 1 1 26 1 1 10 1 1 1 1 1 1 1 1 1 1 1 50 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 26 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 25 1 1 1 1...

output:

6615361583

result:

ok 1 number(s): "6615361583"

Test #17:

score: 0
Accepted
time: 2274ms
memory: 35876kb

input:

44000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 6 1 16 1 1 1 1 104 1 1 1 1 1 1 50 23 1 1 1 1 1 1 23 1 18 1 1 1 1 1 1 1 28 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 12 1 1 1 1 1 1 1 49 1 1 1 1 1 1 1 1 1 1 1 1 53 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 76 1 1 1 1 1 1 1 1 1 149 1 1 1 1 1 0 1 1...

output:

6575348967

result:

ok 1 number(s): "6575348967"

Test #18:

score: 0
Accepted
time: 2644ms
memory: 33812kb

input:

43000 200000
1 53 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 15 1 1 1 1 104 1 1 1 1 1 1 1 1 20 1 1 1 1 1 1 1 16 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 13 1 1 1 1 1 1 1 1 1 1 1 1 1 7 1 1 1 65 1 1 1 1 138 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 15 62 1 1 1 1...

output:

6527389951

result:

ok 1 number(s): "6527389951"

Test #19:

score: 0
Accepted
time: 3036ms
memory: 33632kb

input:

42000 200000
1 1 1 1 1 1 1 1 23 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 239 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 10 1 58 1 ...

output:

6480594507

result:

ok 1 number(s): "6480594507"

Test #20:

score: 0
Accepted
time: 3626ms
memory: 33604kb

input:

41000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 43 1 1 1 1 1 1 1 1 1 85 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 58 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 152 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6440851777

result:

ok 1 number(s): "6440851777"

Test #21:

score: 0
Accepted
time: 3738ms
memory: 35060kb

input:

40800 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 398 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 18 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6433344943

result:

ok 1 number(s): "6433344943"

Test #22:

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

input:

40500 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 151 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6419515129

result:

ok 1 number(s): "6419515129"

Test #23:

score: 0
Accepted
time: 2653ms
memory: 35356kb

input:

40300 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6413828837

result:

ok 1 number(s): "6413828837"

Test #24:

score: 0
Accepted
time: 1948ms
memory: 36060kb

input:

40200 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6406509705

result:

ok 1 number(s): "6406509705"

Test #25:

score: 0
Accepted
time: 987ms
memory: 36272kb

input:

40100 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 353 1 1 1 1 1 1 1 1...

output:

6394891119

result:

ok 1 number(s): "6394891119"

Test #26:

score: 0
Accepted
time: 721ms
memory: 34912kb

input:

40080 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6353150219

result:

ok 1 number(s): "6353150219"

Test #27:

score: 0
Accepted
time: 537ms
memory: 36408kb

input:

40060 200000
1 1 1 1 1 1 1 1 1 1 1992 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6324862643

result:

ok 1 number(s): "6324862643"

Test #28:

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

input:

40030 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6148794579

result:

ok 1 number(s): "6148794579"

Test #29:

score: 0
Accepted
time: 64ms
memory: 33636kb

input:

40020 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

4915254493

result:

ok 1 number(s): "4915254493"

Test #30:

score: 0
Accepted
time: 21ms
memory: 28540kb

input:

40010 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

40961024

result:

ok 1 number(s): "40961024"

Test #31:

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

input:

40005 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

1280032

result:

ok 1 number(s): "1280032"

Test #32:

score: 0
Accepted
time: 11ms
memory: 28788kb

input:

40003 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

320008

result:

ok 1 number(s): "320008"

Test #33:

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

input:

40002 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

160004

result:

ok 1 number(s): "160004"

Test #34:

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

input:

40001 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

80002

result:

ok 1 number(s): "80002"

Test #35:

score: 0
Accepted
time: 179ms
memory: 34564kb

input:

150000 200000
4 1 2 1 3 1 1 1 0 1 2 1 1 3 1 1 1 1 0 4 1 1 3 1 1 3 1 0 2 1 0 1 0 0 1 0 3 6 1 0 3 0 1 3 2 5 0 0 0 1 3 0 2 1 5 0 1 1 1 2 1 1 0 1 1 1 0 0 0 3 1 1 6 3 0 0 3 1 0 3 1 5 0 1 2 1 5 1 3 3 2 0 0 1 2 5 0 0 0 1 1 1 1 0 3 4 2 0 1 0 0 1 0 1 0 0 0 1 1 1 1 0 1 1 3 1 1 1 1 2 0 1 1 1 0 1 1 1 0 1 5 1 2 ...

output:

16598916037

result:

ok 1 number(s): "16598916037"

Test #36:

score: 0
Accepted
time: 163ms
memory: 35420kb

input:

160000 200000
2 0 1 1 0 0 0 0 1 0 0 0 1 0 1 1 4 0 1 0 3 0 0 2 1 2 1 4 1 1 1 1 2 1 1 6 1 1 3 0 0 2 0 0 1 0 0 0 1 1 1 1 0 8 4 0 4 1 1 1 0 0 1 1 1 1 1 1 3 1 5 0 5 4 1 1 0 1 2 0 0 1 0 4 4 3 1 1 0 1 0 1 1 0 2 1 3 1 4 5 0 0 0 0 1 1 1 3 1 1 0 3 1 3 0 1 1 2 0 3 1 2 5 2 3 1 3 0 0 1 0 0 1 4 1 0 1 4 3 0 1 1 0 ...

output:

17975355171

result:

ok 1 number(s): "17975355171"

Test #37:

score: 0
Accepted
time: 159ms
memory: 37660kb

input:

170000 200000
5 1 0 0 7 3 1 0 1 0 0 1 1 2 5 0 0 0 1 1 0 2 1 0 1 0 1 4 0 1 2 2 0 1 1 1 1 3 0 2 3 0 2 1 1 1 1 1 0 1 0 1 0 3 1 1 0 0 1 0 1 1 1 0 0 3 1 1 0 2 1 0 0 0 0 0 2 1 0 1 1 0 1 1 1 2 0 1 1 1 0 1 0 0 6 1 3 1 8 1 0 0 3 0 1 3 0 0 3 1 1 1 0 1 0 1 1 1 1 1 0 0 2 0 0 1 1 1 4 0 0 1 0 0 0 0 0 1 0 1 1 4 0 ...

output:

19302687621

result:

ok 1 number(s): "19302687621"

Test #38:

score: 0
Accepted
time: 145ms
memory: 36480kb

input:

180000 200000
1 1 0 1 1 1 0 4 2 0 1 1 1 5 0 0 0 1 0 3 1 1 1 14 0 0 1 0 0 0 0 0 4 0 1 3 2 2 3 0 1 0 1 2 4 4 6 0 1 0 1 1 0 2 0 0 3 1 7 3 1 1 2 1 0 1 0 0 1 1 1 0 2 1 0 1 1 1 1 1 2 0 1 2 1 1 0 1 1 1 2 1 1 1 0 1 1 2 1 1 0 1 1 0 1 0 1 1 0 1 2 2 1 0 1 1 1 0 0 2 0 1 0 1 0 6 0 1 2 0 0 2 1 0 0 3 1 1 1 0 7 1 1...

output:

20620443627

result:

ok 1 number(s): "20620443627"

Test #39:

score: 0
Accepted
time: 145ms
memory: 36108kb

input:

190000 200000
0 1 2 0 0 1 1 0 1 0 0 0 0 3 0 5 0 0 1 2 1 0 1 0 0 2 0 1 1 0 0 1 1 6 2 2 1 0 2 1 3 1 1 1 1 0 1 1 2 0 1 0 0 1 1 0 1 2 1 0 0 1 1 0 2 0 1 2 1 0 1 0 1 1 1 0 0 1 1 0 2 0 1 0 0 1 1 0 0 0 0 1 0 2 0 0 2 1 0 5 0 3 0 0 1 2 0 0 1 2 0 1 0 2 3 1 1 0 1 3 1 1 1 0 0 0 0 5 0 2 1 0 1 0 1 1 0 2 5 1 0 3 4 ...

output:

22057165057

result:

ok 1 number(s): "22057165057"

Test #40:

score: 0
Accepted
time: 135ms
memory: 37364kb

input:

199000 200000
1 0 0 1 1 0 1 0 1 4 1 1 0 0 0 0 0 1 0 0 7 0 3 1 3 0 0 1 1 3 0 4 1 1 0 1 2 1 1 4 2 5 1 0 0 0 0 0 2 5 2 0 1 1 1 1 0 1 0 2 1 1 1 3 1 0 0 1 1 1 1 1 0 2 2 0 1 1 1 0 2 1 1 1 1 0 2 2 1 0 0 0 0 0 5 1 0 0 0 1 0 0 1 0 0 1 0 0 1 2 1 1 1 0 0 1 0 1 1 0 3 1 1 1 1 0 1 0 0 3 4 0 0 0 1 0 0 2 2 0 1 2 2 ...

output:

23338533811

result:

ok 1 number(s): "23338533811"

Test #41:

score: 0
Accepted
time: 136ms
memory: 37720kb

input:

198000 200000
1 1 0 1 2 1 4 0 0 0 5 0 0 2 0 1 0 1 0 1 2 1 3 2 1 3 2 0 2 0 0 1 1 1 0 1 2 1 0 1 0 0 1 1 2 3 1 0 1 1 0 6 3 0 1 0 0 1 1 0 1 1 1 1 0 1 0 0 0 1 1 0 1 0 1 1 1 2 1 0 1 0 2 5 1 1 0 1 1 1 0 0 1 2 1 1 0 0 0 0 2 1 3 0 1 0 4 2 0 0 2 2 2 1 1 0 0 2 1 0 0 1 1 0 0 1 1 0 1 0 1 0 1 0 1 1 0 0 1 0 1 0 2 ...

output:

23205443235

result:

ok 1 number(s): "23205443235"

Test #42:

score: 0
Accepted
time: 133ms
memory: 37388kb

input:

197000 200000
1 0 1 1 0 0 3 0 0 1 2 1 0 0 1 1 1 1 1 1 1 3 2 1 1 1 1 0 0 0 1 4 1 1 3 1 0 3 1 1 2 0 0 1 0 0 0 0 1 0 0 1 0 1 0 2 3 0 1 1 0 2 1 2 1 1 1 1 1 0 1 0 1 4 1 0 1 1 1 0 1 0 1 0 1 2 1 1 0 1 1 2 1 0 1 1 0 1 0 2 1 0 1 0 2 1 0 1 0 0 1 0 0 2 0 0 3 1 0 0 1 6 1 0 5 0 0 4 0 0 1 2 3 0 0 0 2 1 1 0 0 0 0 ...

output:

23008514485

result:

ok 1 number(s): "23008514485"

Test #43:

score: 0
Accepted
time: 135ms
memory: 38944kb

input:

196000 200000
2 1 1 1 0 2 1 2 0 1 2 0 3 1 0 0 0 1 2 1 0 1 0 1 0 0 0 5 0 1 3 0 5 1 1 3 5 1 1 1 0 0 0 4 0 0 1 1 4 1 1 1 0 0 0 1 5 1 0 0 1 5 1 4 0 2 2 3 1 0 0 0 2 1 4 0 1 3 0 1 1 2 0 0 0 2 0 2 1 0 3 1 0 0 0 1 1 1 1 1 0 1 0 0 0 1 0 1 4 1 0 0 0 1 0 0 0 0 4 1 0 1 1 0 1 1 1 1 0 1 0 1 3 0 0 0 0 1 0 1 2 1 0 ...

output:

22830578635

result:

ok 1 number(s): "22830578635"

Test #44:

score: 0
Accepted
time: 137ms
memory: 37100kb

input:

195000 200000
0 1 1 1 0 0 0 2 0 1 0 0 0 3 0 3 1 0 1 0 0 1 4 0 0 0 1 1 5 0 0 3 2 1 1 1 2 0 1 1 0 0 3 0 1 1 0 1 0 1 0 4 1 1 1 0 1 1 1 1 1 0 1 2 0 0 0 1 0 4 1 2 0 1 0 0 1 4 1 0 1 2 1 1 2 1 1 0 1 1 4 1 0 1 1 0 2 0 0 1 2 0 0 5 0 1 1 0 0 0 2 0 0 2 0 4 1 0 1 4 0 3 1 0 4 0 2 0 1 1 0 0 1 0 1 1 1 0 4 1 3 1 1 ...

output:

22728530185

result:

ok 1 number(s): "22728530185"

Test #45:

score: 0
Accepted
time: 200ms
memory: 33568kb

input:

130000 200000
1 1 1 6 0 1 0 3 1 2 1 0 1 2 1 1 4 1 1 1 1 1 3 0 4 1 1 4 1 7 1 1 0 1 2 1 1 1 4 3 0 2 0 1 0 3 1 1 8 4 1 1 1 0 0 1 1 1 0 7 1 3 1 0 1 1 1 0 1 0 2 0 9 1 1 1 1 3 4 1 3 2 1 2 1 0 0 1 3 7 1 0 0 1 1 2 0 0 1 1 1 0 0 4 1 5 2 1 1 8 1 0 0 1 2 1 1 0 1 1 2 3 9 1 1 4 3 2 2 1 1 0 1 1 1 1 4 5 4 1 1 0 0 ...

output:

14134819093

result:

ok 1 number(s): "14134819093"

Test #46:

score: 0
Accepted
time: 216ms
memory: 33320kb

input:

120000 200000
4 1 1 4 4 2 0 4 1 1 0 1 4 3 1 8 0 1 1 0 0 0 3 3 0 1 1 1 1 1 0 2 3 1 9 0 2 3 2 0 2 1 16 1 7 0 1 1 1 1 1 3 2 1 5 1 1 2 3 4 1 1 6 1 0 1 0 3 1 1 0 1 1 1 3 1 3 1 1 0 1 0 3 8 1 3 0 1 13 0 1 0 1 0 2 1 1 1 1 0 4 0 1 0 1 2 3 1 4 0 1 2 0 1 0 1 1 5 3 0 2 1 0 1 3 1 0 1 1 0 1 4 1 2 1 1 0 4 1 0 1 0 ...

output:

13048112685

result:

ok 1 number(s): "13048112685"

Test #47:

score: 0
Accepted
time: 238ms
memory: 34200kb

input:

110000 200000
1 1 8 4 8 1 0 0 1 3 1 1 9 0 1 5 1 1 1 3 3 1 16 4 1 1 4 0 0 5 0 0 2 1 0 0 4 1 1 1 3 2 1 1 1 1 2 1 5 3 1 5 1 5 0 3 2 1 3 1 5 1 1 0 1 1 1 5 1 0 0 1 0 1 1 0 1 1 1 1 2 1 1 2 1 5 1 0 0 2 0 2 1 1 1 6 1 1 8 1 0 2 4 1 4 1 3 1 1 1 1 1 1 1 1 1 3 1 1 0 1 1 2 1 1 1 0 1 1 1 6 2 1 5 1 5 1 1 1 1 1 1 0...

output:

11875762941

result:

ok 1 number(s): "11875762941"

Test #48:

score: 0
Accepted
time: 270ms
memory: 32908kb

input:

100000 200000
0 2 1 5 1 0 1 1 1 1 1 3 0 4 8 1 1 1 1 0 0 1 1 1 1 1 4 0 4 1 1 5 6 2 1 1 1 1 1 2 1 1 1 3 1 3 1 0 1 0 6 1 1 1 4 1 1 5 8 0 1 6 1 1 1 0 4 9 7 1 10 1 1 3 4 1 1 1 1 3 3 0 2 0 1 1 2 1 1 1 1 1 1 1 0 0 4 3 2 2 1 5 1 2 1 1 10 1 1 1 1 1 1 3 0 1 1 1 1 1 4 1 1 0 0 1 4 1 5 5 1 5 0 1 3 2 1 0 4 9 3 1 ...

output:

10871306605

result:

ok 1 number(s): "10871306605"

Test #49:

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

input:

40001 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

80002

result:

ok 1 number(s): "80002"

Test #50:

score: 0
Accepted
time: 13ms
memory: 31548kb

input:

40002 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

160004

result:

ok 1 number(s): "160004"

Test #51:

score: 0
Accepted
time: 12ms
memory: 31136kb

input:

40005 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

1280032

result:

ok 1 number(s): "1280032"

Test #52:

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

input:

40010 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

40961024

result:

ok 1 number(s): "40961024"

Test #53:

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

input:

40020 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

4626623607

result:

ok 1 number(s): "4626623607"

Test #54:

score: 0
Accepted
time: 313ms
memory: 34820kb

input:

40040 200000
1 1 1 1 1 1 7667 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2139 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6244348043

result:

ok 1 number(s): "6244348043"

Test #55:

score: 0
Accepted
time: 540ms
memory: 33656kb

input:

40060 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6329597379

result:

ok 1 number(s): "6329597379"

Test #56:

score: 0
Accepted
time: 766ms
memory: 35992kb

input:

40080 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6393987891

result:

ok 1 number(s): "6393987891"

Test #57:

score: 0
Accepted
time: 968ms
memory: 33668kb

input:

40100 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6393848161

result:

ok 1 number(s): "6393848161"

Test #58:

score: 0
Accepted
time: 1881ms
memory: 35052kb

input:

40200 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6404886465

result:

ok 1 number(s): "6404886465"

Test #59:

score: 0
Accepted
time: 3092ms
memory: 33668kb

input:

40400 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 420 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 563 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6415036421

result:

ok 1 number(s): "6415036421"

Test #60:

score: 0
Accepted
time: 3639ms
memory: 34784kb

input:

40600 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 17 1 1 1 1 23 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6423932929

result:

ok 1 number(s): "6423932929"

Test #61:

score: 0
Accepted
time: 3702ms
memory: 35988kb

input:

40800 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 791 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6432643769

result:

ok 1 number(s): "6432643769"

Test #62:

score: 0
Accepted
time: 3729ms
memory: 36488kb

input:

41000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 235 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 19 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 3 1 309 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6440202809

result:

ok 1 number(s): "6440202809"

Test #63:

score: 0
Accepted
time: 3021ms
memory: 35892kb

input:

42000 200000
1 1 1 1 1 1 1 1 1 1 1 57 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 54 1 1 1 1 1 1 1 26 1 1 1 1 1 1 1 1 1 1 1 1 60 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 46 1 1 1 1 180 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 65 1 1 1 1 1 1 1 141 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6477624213

result:

ok 1 number(s): "6477624213"

Test #64:

score: 0
Accepted
time: 2210ms
memory: 35776kb

input:

44000 200000
1 1 1 1 1 1 1 1 1 1 1 1 11 1 1 1 1 90 60 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 44 1 1 1 1 1 1 1 1 1 1 47 37 1 1 1 1 1 1 1 1 14 25 1 198 74 1 1 1 1 1 1 1 24 1 1 1 1 1 1 1 1 1 1 1 1 23 13 1 1 1 1 24 1 1 1 104 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 65 1 1 1 1 1 1...

output:

6550566425

result:

ok 1 number(s): "6550566425"

Test #65:

score: 0
Accepted
time: 1316ms
memory: 33324kb

input:

48000 200000
1 1 1 1 1 1 1 1 1 1 1 21 1 1 1 1 1 1 1 40 1 1 1 1 1 1 1 1 1 1 1 1 49 1 19 1 6 1 1 1 2 1 1 1 39 1 1 15 1 1 9 1 1 1 1 1 33 12 5 1 51 48 1 1 1 13 3 1 1 35 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 19 1 1 1 1 1 1 1 1 1 25 1 1 1 1 1 1 1 1 40 1 35 35 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 1 1 5 1 36 1...

output:

6674182047

result:

ok 1 number(s): "6674182047"

Test #66:

score: 0
Accepted
time: 659ms
memory: 35144kb

input:

56000 200000
1 25 1 12 5 1 2 1 1 1 1 1 6 1 1 32 1 1 1 13 9 1 1 9 1 15 22 1 1 7 1 1 1 1 1 1 1 27 4 1 1 1 2 1 28 1 1 1 1 1 8 1 10 1 2 2 1 5 23 1 12 1 1 1 1 1 1 1 1 16 8 1 1 2 1 3 6 2 1 7 1 1 1 1 1 19 1 1 1 3 1 1 1 1 16 1 1 1 1 3 1 7 1 4 1 1 3 4 1 1 1 2 2 1 1 1 3 1 20 1 1 21 1 1 1 1 1 1 2 1 1 2 1 1 1 1...

output:

6844905709

result:

ok 1 number(s): "6844905709"

Test #67:

score: 0
Accepted
time: 264ms
memory: 34508kb

input:

72000 200000
1 5 1 2 1 8 6 1 15 2 2 7 14 2 1 1 1 1 2 1 5 1 1 1 1 1 1 8 2 1 1 1 3 1 4 2 1 8 9 1 7 1 1 1 9 6 2 5 1 3 1 9 1 1 12 1 1 5 5 1 6 1 1 1 1 1 1 1 6 1 1 1 6 1 2 5 1 4 1 6 1 1 1 1 1 1 2 2 1 6 3 3 7 3 7 1 7 3 1 4 1 1 8 7 1 2 1 4 1 1 1 3 5 6 3 1 2 2 1 2 1 1 5 1 1 1 1 2 1 3 1 1 5 3 8 7 4 2 1 6 7 1 ...

output:

6880182507

result:

ok 1 number(s): "6880182507"

Test #68:

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

input:

104000 200000
3 1 1 1 3 1 2 1 3 3 1 2 5 2 2 1 2 2 1 4 2 3 1 1 1 2 1 2 2 2 2 3 1 1 3 3 2 2 2 2 2 1 1 1 3 2 2 2 4 5 3 3 1 2 5 2 2 2 2 2 1 1 5 1 2 2 3 1 4 1 3 1 2 1 2 2 1 2 2 3 3 2 1 2 2 1 2 3 2 1 3 1 2 2 3 2 1 1 2 2 2 1 2 2 2 1 1 1 1 2 2 1 2 2 1 1 2 2 2 3 4 2 1 2 2 1 1 7 1 1 1 3 3 2 2 1 3 1 5 2 2 2 1 ...

output:

5374274367

result:

ok 1 number(s): "5374274367"

Test #69:

score: 0
Accepted
time: 77ms
memory: 31580kb

input:

120000 200000
2 1 3 3 2 1 2 2 3 2 2 0 1 1 2 2 2 1 0 1 1 3 1 2 1 1 1 1 1 2 1 2 0 3 2 0 3 2 1 3 2 4 1 2 1 1 1 1 1 1 2 0 2 0 1 2 2 0 2 1 1 2 2 1 2 2 1 2 3 2 2 0 1 2 3 1 1 1 2 2 3 2 0 1 2 2 1 1 3 2 2 0 0 2 5 1 1 2 2 1 2 1 1 3 2 1 2 2 3 1 1 2 2 2 1 2 1 1 2 2 0 2 1 0 2 2 2 2 2 2 1 2 2 1 1 0 4 1 0 2 1 0 1 ...

output:

6745448219

result:

ok 1 number(s): "6745448219"

Test #70:

score: 0
Accepted
time: 101ms
memory: 31404kb

input:

110000 200000
2 5 2 2 1 2 0 2 1 1 1 2 0 1 1 1 1 2 2 1 3 3 4 2 2 1 2 1 1 1 1 1 2 3 1 4 0 0 1 1 0 0 2 2 0 1 3 1 4 1 1 2 3 2 1 1 1 0 3 2 1 1 3 2 2 3 2 2 0 2 1 1 2 1 2 2 1 1 2 4 2 1 2 2 1 1 2 1 1 1 0 1 4 3 3 1 3 2 5 1 1 0 0 3 2 1 1 2 4 2 2 1 5 1 1 1 0 0 1 5 2 1 1 0 3 1 2 2 1 0 4 2 0 2 1 3 1 4 1 1 1 3 2 ...

output:

7712193683

result:

ok 1 number(s): "7712193683"

Test #71:

score: 0
Accepted
time: 226ms
memory: 32392kb

input:

90000 200000
2 2 2 1 8 1 1 1 4 12 1 1 2 4 4 1 15 3 1 4 2 1 6 2 1 1 4 3 1 1 2 1 1 1 6 2 4 9 3 1 3 0 3 7 2 2 3 3 1 8 2 2 1 0 1 1 1 0 3 2 2 1 0 4 1 0 1 3 1 1 1 1 1 1 0 1 4 1 5 2 2 2 3 4 2 1 1 1 1 1 2 5 2 5 1 1 3 1 0 1 7 1 1 1 1 1 0 3 1 2 5 1 2 1 1 1 0 1 1 3 3 3 2 1 1 3 12 10 1 1 1 4 2 1 0 1 12 1 0 0 0 ...

output:

8718437229

result:

ok 1 number(s): "8718437229"

Test #72:

score: 0
Accepted
time: 326ms
memory: 35908kb

input:

80000 200000
2 6 3 1 1 1 2 8 1 11 1 1 1 1 1 13 0 1 5 1 1 1 3 0 1 4 1 1 6 1 2 3 1 1 1 1 0 0 9 0 1 2 1 3 1 4 2 1 1 3 6 1 1 3 9 1 22 1 1 1 2 0 0 1 1 1 1 5 4 1 1 4 1 0 2 1 1 4 14 1 0 1 1 1 1 1 1 2 1 1 3 3 0 0 6 1 1 4 2 1 6 7 1 2 1 1 1 1 0 1 4 1 1 1 1 3 2 1 1 1 3 0 0 1 2 9 9 1 1 15 1 7 0 0 4 2 1 6 2 8 0 ...

output:

8892185533

result:

ok 1 number(s): "8892185533"

Test #73:

score: 0
Accepted
time: 548ms
memory: 35876kb

input:

70000 200000
1 1 4 1 0 1 1 1 1 5 1 0 1 1 1 1 1 1 1 6 1 1 1 1 3 2 1 13 0 4 1 1 8 1 11 1 7 1 1 1 1 1 2 1 1 1 1 1 1 2 2 1 1 1 1 6 1 1 0 0 0 10 5 1 0 0 1 1 6 1 1 1 1 18 1 9 1 1 1 0 0 6 1 1 0 0 1 8 0 1 1 1 1 0 14 1 1 1 4 1 5 8 2 20 1 0 4 1 0 0 0 1 1 1 1 1 1 10 0 1 3 1 1 3 19 1 1 0 0 1 1 0 1 1 1 1 14 0 0 ...

output:

8895563309

result:

ok 1 number(s): "8895563309"

Test #74:

score: 0
Accepted
time: 1107ms
memory: 35388kb

input:

60000 200000
1 1 29 1 1 1 19 1 61 32 1 1 18 1 0 6 20 1 1 1 1 24 0 0 1 1 16 1 1 1 0 46 22 1 1 1 40 1 1 4 2 1 1 1 1 1 34 1 0 1 14 1 1 10 1 1 1 1 1 1 1 5 1 0 1 1 1 0 8 14 1 1 0 31 1 1 1 1 1 15 11 1 0 1 0 1 1 1 1 0 5 1 0 1 9 4 1 1 1 0 0 1 3 1 8 1 0 0 1 0 0 1 1 1 5 1 1 1 1 5 1 0 37 1 0 1 1 0 1 0 1 1 11 0...

output:

8715188297

result:

ok 1 number(s): "8715188297"

Test #75:

score: 0
Accepted
time: 1989ms
memory: 36808kb

input:

55000 200000
1 0 1 0 1 1 1 49 1 0 1 16 1 1 0 1 1 11 1 1 1 1 1 1 10 1 0 1 0 0 0 0 0 1 1 1 1 60 1 23 1 0 0 1 46 1 1 0 1 1 1 25 1 2 1 0 1 1 1 0 1 0 0 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 33 0 1 1 1 0 17 1 1 0 1 0 1 1 1 1 0 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 106 1 1 1 0 1 6 0 1 0 0 1 1 50 28 1 1 1 1 0 12 1 ...

output:

8586958759

result:

ok 1 number(s): "8586958759"

Test #76:

score: 0
Accepted
time: 2256ms
memory: 37136kb

input:

54000 200000
0 1 0 0 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 0 0 1 0 1 1 1 1 0 1 1 0 1 1 0 1 1 0 1 0 1 1 0 1 0 1 1 1 1 0 0 1 1 1 0 0 1 1 1 1 0 1 1 0 1 1 0 1 1 1 53 0 0 1 0 1 1 1 0 0 0 1 1 1 1 21 0 1 1 1 0 0 0 1 59 1 1 1 1 7 1 1 58 1 1 1 1 30 0 1 0 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1 1 0 1 1 1 1 1 0 1 1 1 1 52 0 0...

output:

8546536201

result:

ok 1 number(s): "8546536201"

Test #77:

score: 0
Accepted
time: 2592ms
memory: 37448kb

input:

53000 200000
0 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 1 1 1 0 1 1 1 0 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 0 1 0 53 0 40 1 32 1 1 1 1 0 1 1 1 28 1 38 1 1 1 1 1 1 1 0 1 1 1 0 1 1 0 1 1 100 33 1 1 1 1 1 1 1 1 1 0 1 0 1 0 1 1 1 0 1 0 1 1 0 1 1 1 1 1 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 14 0 1 1 0 1 54 1 1 0 0 1...

output:

8510129081

result:

ok 1 number(s): "8510129081"

Test #78:

score: 0
Accepted
time: 3168ms
memory: 37112kb

input:

52000 200000
1 1 1 0 1 1 0 1 1 1 0 1 1 0 1 1 0 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 0 0 1 0 0 1 1 1 1 0 1 1 1 1 0 0 1 1 0 1 1 1 0 1 0 1 1 163 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 258 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 1 1 0 1 1 26 1 0 1 13 1 1 1 73 1 1 ...

output:

8481623611

result:

ok 1 number(s): "8481623611"

Test #79:

score: 0
Accepted
time: 93ms
memory: 31944kb

input:

130000 200000
1 1 1 1 2 2 1 1 2 1 2 3 2 3 2 4 3 2 1 1 1 1 2 1 2 2 1 1 0 2 1 0 2 2 3 1 1 2 3 2 2 1 2 2 2 0 1 2 2 1 2 1 4 0 2 1 2 3 2 1 3 0 3 3 3 2 0 1 1 2 1 1 3 0 2 2 2 5 2 2 2 0 2 1 3 2 3 0 0 2 2 1 0 0 1 0 2 2 2 1 2 0 1 0 1 1 2 1 2 2 4 2 1 0 0 3 2 0 2 1 3 2 2 1 2 1 0 1 2 3 2 1 0 0 1 0 2 2 2 2 1 2 1 ...

output:

8747015491

result:

ok 1 number(s): "8747015491"

Test #80:

score: 0
Accepted
time: 125ms
memory: 33264kb

input:

120000 200000
3 3 1 0 1 1 1 0 2 1 2 2 4 4 2 0 1 2 2 1 1 2 2 1 0 6 4 0 1 0 3 2 2 1 2 0 2 1 1 2 2 0 2 0 2 2 0 2 4 3 2 1 3 2 1 2 1 2 4 3 1 0 2 1 0 2 0 1 1 2 2 1 2 0 1 2 3 0 1 3 0 1 3 2 2 1 1 0 0 2 0 3 2 0 1 3 2 1 4 2 1 2 1 0 0 1 3 1 3 1 2 4 0 1 1 2 2 2 2 4 4 2 2 2 10 2 1 2 4 2 0 0 1 1 2 1 4 2 1 0 0 1 0...

output:

9720298457

result:

ok 1 number(s): "9720298457"

Test #81:

score: 0
Accepted
time: 253ms
memory: 35600kb

input:

100000 200000
3 1 3 1 0 1 1 5 2 3 3 6 1 10 1 0 0 1 3 2 1 0 1 1 0 1 2 1 1 1 1 1 1 4 1 1 3 0 1 4 2 1 1 3 0 1 0 7 3 3 1 1 5 1 1 1 1 5 0 0 6 1 2 3 9 0 1 1 1 4 2 0 4 5 1 2 4 2 1 1 3 2 0 2 1 1 2 4 1 0 1 1 1 2 1 7 2 3 1 0 0 0 1 0 1 1 1 2 3 0 2 0 2 1 2 0 1 2 1 3 1 5 1 2 1 1 1 1 1 0 2 1 2 0 0 1 1 2 2 1 1 1 0...

output:

10714478349

result:

ok 1 number(s): "10714478349"

Test #82:

score: 0
Accepted
time: 343ms
memory: 33732kb

input:

90000 200000
0 1 1 29 7 8 1 1 1 1 2 0 6 1 1 1 1 2 3 0 4 2 1 1 1 9 1 6 1 0 1 3 1 3 13 1 4 2 0 0 5 0 8 0 1 1 5 1 2 8 1 13 1 0 1 4 1 1 11 6 1 0 8 1 5 1 3 0 0 0 0 1 1 1 1 1 1 1 11 0 0 0 0 0 0 1 1 1 1 3 1 2 0 1 1 8 1 0 16 2 5 1 0 1 1 2 0 5 1 17 1 1 1 1 5 1 0 1 0 2 0 1 0 0 0 7 0 0 3 0 1 0 1 2 2 2 1 1 4 6 ...

output:

10902301123

result:

ok 1 number(s): "10902301123"

Test #83:

score: 0
Accepted
time: 571ms
memory: 34580kb

input:

80000 200000
1 19 22 7 0 1 1 1 1 9 0 1 1 4 0 10 0 0 1 4 1 1 1 9 0 1 1 1 1 1 0 1 1 15 14 6 9 3 1 1 5 0 0 0 5 6 3 1 2 1 0 1 0 1 35 2 1 1 0 0 1 16 1 0 1 0 3 2 1 1 1 1 1 0 1 1 2 1 1 1 1 1 0 1 0 4 1 1 0 1 1 6 1 0 0 1 10 0 1 1 0 0 7 0 0 0 0 1 1 0 1 0 1 1 1 1 2 17 0 1 1 1 0 11 1 21 5 1 1 1 1 0 1 0 0 1 1 0 ...

output:

10882604805

result:

ok 1 number(s): "10882604805"

Test #84:

score: 0
Accepted
time: 1155ms
memory: 36444kb

input:

70000 200000
1 1 1 1 1 1 1 15 0 0 1 1 0 0 1 0 0 1 1 0 1 0 0 1 1 0 1 14 4 1 5 0 0 1 0 1 3 0 1 1 1 1 1 0 1 0 13 35 0 0 1 1 1 0 1 1 1 8 24 1 0 1 0 1 0 19 1 1 0 1 1 0 1 1 8 1 0 1 0 15 0 0 11 0 1 0 28 0 49 1 3 1 1 1 21 0 0 0 1 1 0 1 1 0 1 0 1 1 1 1 0 1 1 1 1 0 0 1 1 1 5 1 0 1 48 0 1 1 1 13 1 1 0 1 1 1 1 ...

output:

10726599245

result:

ok 1 number(s): "10726599245"

Test #85:

score: 0
Accepted
time: 1984ms
memory: 36808kb

input:

65000 200000
53 1 0 1 1 0 0 1 1 0 16 0 1 2 1 1 0 20 1 1 26 0 1 1 1 0 1 0 1 2 57 1 107 1 1 1 1 3 1 0 1 1 1 0 0 1 1 1 20 1 1 1 1 1 1 1 0 0 0 1 0 1 1 0 11 1 1 0 1 0 1 1 1 1 1 0 1 0 0 1 1 0 0 1 1 0 1 1 0 33 1 1 1 0 9 0 0 0 0 1 0 1 1 1 0 0 1 1 0 1 1 19 1 1 1 1 0 0 1 7 0 1 1 1 1 0 1 1 0 1 1 0 1 1 1 1 1 1 ...

output:

10585560517

result:

ok 1 number(s): "10585560517"

Test #86:

score: 0
Accepted
time: 2256ms
memory: 35200kb

input:

64000 200000
0 0 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 2 1 0 1 1 1 1 1 1 7 1 1 1 0 0 0 1 0 1 1 0 0 1 1 0 1 1 1 1 0 1 1 1 0 0 1 1 0 0 0 0 0 0 55 0 1 1 1 1 0 0 15 0 0 1 32 102 1 1 1 1 1 1 1 1 1 40 1 1 1 0 1 0 1 1 0 1 0 1 0 0 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 9 1 1 1 0 0 1 1 1 1 1 1 14 1 0 0 1 0 1 1 ...

output:

10542275555

result:

ok 1 number(s): "10542275555"

Test #87:

score: 0
Accepted
time: 2618ms
memory: 36980kb

input:

63000 200000
1 0 0 1 1 0 1 0 0 1 1 1 152 1 1 1 0 1 1 1 1 0 0 1 0 1 0 1 1 0 0 0 1 0 1 0 1 0 0 1 1 1 0 1 1 1 0 0 1 1 1 0 0 0 1 1 43 1 0 0 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 0 0 1 1 31 0 0 1 0 0 1 0 1 1 1 1 1 1 3 1 1 0 0 60 1 1 1 0 1 1 1 1 1 1 0 1 0 1 0 1 0 0 0 0 1 1 1 0 1 1 1 0 1 1 0 0 1 1 1 1 1 1 0 0 0 0 ...

output:

10510594287

result:

ok 1 number(s): "10510594287"

Test #88:

score: 0
Accepted
time: 3121ms
memory: 35456kb

input:

62000 200000
0 1 0 1 0 0 1 0 1 0 1 0 1 1 1 1 0 1 0 1 1 1 1 0 1 0 1 0 1 1 0 0 0 1 1 1 0 1 0 1 0 1 1 0 0 1 0 1 1 1 0 1 1 1 1 1 1 0 1 0 1 1 1 1 0 0 0 1 0 0 1 1 0 1 1 0 1 1 0 98 1 1 1 1 0 0 0 0 1 1 0 0 0 0 1 1 1 1 1 0 0 1 0 1 0 1 0 1 1 0 0 0 0 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 0 1 0 0 1 1 1 0 1 1 ...

output:

10477303837

result:

ok 1 number(s): "10477303837"

Test #89:

score: 0
Accepted
time: 3765ms
memory: 38552kb

input:

61000 200000
0 1 1 91 415 1 415 1 1 0 0 1 1 0 0 0 1 1 0 1 1 1 1 1 1 1 0 0 1 0 1 1 1 0 0 0 1 1 0 1 1 0 1 0 1 0 1 1 1 0 1 0 1 1 0 1 1 0 1 1 1 1 0 0 1 1 1 1 0 1 0 0 0 1 0 0 0 0 1 1 1 1 427 1 1 0 0 1 1 1 1 0 0 1 1 1 0 0 1 0 1 1 0 1 1 0 1 0 1 0 1 0 1 0 0 0 1 1 114 0 1 0 1 1 1 0 0 1 0 1 0 1 0 0 161 1 0 0 ...

output:

10441540213

result:

ok 1 number(s): "10441540213"

Test #90:

score: 0
Accepted
time: 99ms
memory: 32552kb

input:

140000 200000
2 2 1 2 0 0 2 2 0 3 4 1 2 2 1 2 1 3 0 1 2 2 2 2 2 1 2 1 2 2 1 1 3 0 2 1 1 2 1 1 2 2 1 1 0 1 2 0 1 2 1 2 1 0 2 2 3 0 1 2 2 3 1 3 0 2 2 0 1 0 2 1 2 0 0 0 2 3 0 0 0 1 0 1 2 1 1 2 1 2 2 1 2 2 3 1 2 2 2 1 0 1 2 2 2 2 1 2 1 2 2 0 1 2 1 1 2 1 1 0 2 2 1 1 1 2 1 2 0 2 2 2 1 0 0 1 0 2 2 0 1 2 0 ...

output:

10746595211

result:

ok 1 number(s): "10746595211"

Test #91:

score: 0
Accepted
time: 128ms
memory: 35476kb

input:

130000 200000
2 2 1 0 1 1 2 1 0 1 0 2 0 0 1 4 0 1 2 1 0 2 6 1 1 2 2 3 2 1 1 3 0 3 2 3 1 0 4 1 0 3 2 2 1 1 2 5 2 2 0 2 2 0 1 3 4 6 1 1 2 1 1 0 2 0 3 3 5 1 2 1 0 1 1 1 2 0 1 0 1 2 1 0 1 0 3 1 0 2 1 2 0 3 1 0 6 1 1 4 0 4 1 1 3 1 2 2 1 2 5 2 0 0 0 2 5 3 2 2 3 1 2 1 2 1 2 0 0 0 1 2 2 0 1 5 0 2 2 1 0 3 1 ...

output:

11710688677

result:

ok 1 number(s): "11710688677"

Test #92:

score: 0
Accepted
time: 252ms
memory: 35404kb

input:

110000 200000
1 1 1 2 2 1 3 0 1 2 1 3 1 2 0 1 0 1 2 0 2 7 5 2 0 2 2 1 4 5 0 4 3 0 1 3 1 1 2 1 0 1 5 5 0 6 5 1 1 0 5 1 1 4 1 0 2 0 1 1 5 1 3 0 4 0 0 1 3 3 4 0 2 2 0 0 3 0 0 1 1 1 2 5 1 0 1 0 1 1 1 2 1 0 1 2 2 1 3 3 11 2 1 0 0 0 4 1 1 0 0 3 0 0 0 1 1 2 1 1 4 1 4 1 1 0 1 1 0 0 0 0 3 3 0 0 1 1 11 0 10 1...

output:

12718293357

result:

ok 1 number(s): "12718293357"

Test #93:

score: 0
Accepted
time: 364ms
memory: 37216kb

input:

100000 200000
0 5 0 0 8 1 2 1 9 1 1 1 1 1 0 1 7 0 0 0 1 1 0 0 1 1 1 0 1 6 1 1 0 1 0 0 0 5 1 6 6 0 1 0 1 2 0 2 1 0 0 4 1 1 0 4 1 1 1 4 1 4 2 2 1 4 0 2 1 0 1 0 0 5 8 1 1 0 0 1 1 0 0 2 1 1 1 3 1 4 0 0 1 8 1 0 1 1 0 8 1 1 1 9 1 4 0 2 0 1 0 15 8 5 0 17 2 0 1 9 0 1 13 1 4 4 0 1 0 4 0 0 1 7 5 0 1 2 1 4 0 0...

output:

12891943621

result:

ok 1 number(s): "12891943621"

Test #94:

score: 0
Accepted
time: 592ms
memory: 35632kb

input:

90000 200000
0 18 0 2 0 0 0 1 1 0 0 3 0 0 0 1 1 0 1 1 1 0 1 1 1 2 1 4 1 1 1 0 0 1 0 1 0 1 0 0 1 4 1 11 1 0 0 1 1 0 1 25 13 0 0 0 0 2 0 1 1 17 1 1 5 0 1 1 1 0 18 1 1 1 1 0 0 1 0 1 0 0 1 1 1 1 1 0 1 0 0 0 1 6 1 1 1 1 10 0 0 1 1 1 0 0 0 7 3 0 0 1 4 1 1 1 1 1 6 1 0 1 0 1 1 0 0 1 1 1 1 0 6 19 1 1 1 0 1 1...

output:

12897176255

result:

ok 1 number(s): "12897176255"

Test #95:

score: 0
Accepted
time: 1166ms
memory: 38560kb

input:

80000 200000
0 1 0 1 1 3 0 1 1 1 0 0 1 0 1 1 0 1 1 0 1 1 6 7 0 0 0 1 1 1 0 12 1 1 1 24 1 0 0 25 1 1 0 0 0 1 1 1 0 7 0 0 1 0 0 0 1 1 0 1 18 1 0 1 0 0 1 0 0 1 0 0 1 0 0 1 1 1 0 11 0 0 0 1 0 1 1 1 0 1 0 15 0 1 0 0 1 0 1 0 1 0 1 0 13 1 1 1 0 0 0 0 0 1 1 0 0 0 0 1 0 24 40 3 13 1 9 1 1 1 43 0 0 22 0 1 0 0...

output:

12728826669

result:

ok 1 number(s): "12728826669"

Test #96:

score: 0
Accepted
time: 1998ms
memory: 38620kb

input:

75000 200000
1 4 0 4 0 0 1 0 0 1 0 1 15 1 1 10 0 0 0 1 1 1 1 1 1 0 0 0 1 0 0 0 1 1 1 0 43 0 0 0 1 32 1 0 1 1 0 1 0 1 1 1 1 0 1 0 1 1 1 1 0 1 1 0 1 0 0 1 0 0 1 1 1 1 1 1 8 1 1 0 1 1 1 1 1 1 0 0 5 1 0 1 0 0 1 0 4 1 1 0 0 16 0 0 0 0 1 1 1 1 1 1 0 1 1 1 1 1 0 1 1 0 1 51 1 1 1 0 0 0 0 1 19 0 50 1 1 1 0 1...

output:

12580253909

result:

ok 1 number(s): "12580253909"

Test #97:

score: 0
Accepted
time: 2316ms
memory: 38752kb

input:

74000 200000
0 0 0 1 1 1 0 1 0 0 1 0 1 0 0 0 1 0 0 1 0 0 1 1 1 1 0 1 1 0 1 1 1 0 0 0 1 0 1 0 0 1 1 0 0 1 0 0 1 0 1 123 1 0 0 1 0 0 0 1 0 1 1 0 1 0 1 1 1 0 1 1 0 1 1 1 101 1 0 1 1 1 1 0 1 0 1 1 0 0 1 1 1 1 1 1 1 1 1 1 0 1 1 0 0 1 0 0 0 1 0 1 2 1 0 1 1 1 0 1 1 1 0 0 1 0 1 1 0 1 1 1 0 0 15 0 8 0 0 0 1 ...

output:

12550928267

result:

ok 1 number(s): "12550928267"

Test #98:

score: 0
Accepted
time: 2715ms
memory: 36560kb

input:

73000 200000
1 1 0 1 1 1 1 1 1 0 1 1 0 1 1 1 1 1 1 0 0 1 1 1 1 1 0 1 0 0 0 1 16 1 1 0 1 1 0 0 0 0 0 1 1 148 1 1 1 0 1 1 0 0 1 0 1 1 0 1 1 1 0 31 0 1 1 203 0 0 0 0 1 1 0 1 1 1 1 14 0 0 1 1 1 1 0 0 1 46 0 1 1 34 1 0 1 0 0 1 1 0 0 1 1 1 0 0 0 1 1 0 0 0 72 1 1 1 1 0 1 1 0 1 1 1 0 1 0 0 1 0 0 120 1 0 182...

output:

12513485405

result:

ok 1 number(s): "12513485405"

Test #99:

score: 0
Accepted
time: 3135ms
memory: 39500kb

input:

72000 200000
1 1 0 0 1 0 1 1 1 1 0 1 0 0 91 1 0 1 1 1 0 0 1 1 1 0 0 1 0 1 0 0 1 1 1 10 0 0 1 0 1 1 0 1 1 1 1 0 0 0 0 1 0 1 1 0 0 1 1 1 0 0 1 0 0 1 1 0 0 1 0 0 1 0 1 0 0 4 1 1 1 1 1 1 0 1 1 1 0 0 1 0 1 0 1 0 1 0 66 1 1 1 1 0 0 1 1 0 1 0 1 1 1 0 0 1 1 1 1 0 1 1 1 1 0 0 1 1 1 1 1 1 0 1 0 0 1 1 0 1 1 0 ...

output:

12476602933

result:

ok 1 number(s): "12476602933"

Test #100:

score: 0
Accepted
time: 3797ms
memory: 37832kb

input:

71000 200000
0 0 1 1 1 1 1 1 0 0 0 0 0 0 0 1 0 1 1 0 1 0 1 1 1 0 1 0 1 0 0 0 1 1 1 1 0 0 0 1 1 0 0 0 1 1 1 1 1 1 1 1 0 1 0 1 0 1 0 0 28 1 1 1 1 1 1 1 0 1 0 1 0 0 1 1 0 1 1 0 0 0 92 0 1 0 1 1 0 1 1 1 1 0 0 0 1 1 1 0 0 1 0 0 1 1 0 51 0 0 0 1 0 1 0 0 0 0 1 1 0 1 0 1 1 1 1 0 1 1 1 0 1 0 1 0 0 1 1 0 62 1...

output:

12440350831

result:

ok 1 number(s): "12440350831"

Test #101:

score: 0
Accepted
time: 114ms
memory: 37928kb

input:

170000 200000
2 0 2 3 2 0 3 0 2 2 0 2 1 0 2 2 1 2 2 2 2 2 0 0 2 1 2 1 2 0 2 1 0 0 2 0 2 1 2 1 0 0 2 0 2 1 0 0 1 3 2 1 2 2 0 0 1 0 2 2 2 1 0 0 3 0 2 2 0 3 2 2 2 1 0 0 1 1 2 2 2 3 1 1 2 1 0 0 1 0 0 2 3 2 3 2 2 3 2 1 0 0 0 1 2 2 2 1 1 2 2 2 0 1 2 2 2 1 1 3 3 1 2 2 1 1 3 2 2 0 2 2 2 1 0 0 2 0 0 2 2 0 2 ...

output:

16745250085

result:

ok 1 number(s): "16745250085"

Test #102:

score: 0
Accepted
time: 150ms
memory: 37296kb

input:

160000 200000
1 0 1 0 1 3 2 2 0 3 1 1 0 0 1 2 3 0 0 1 2 3 2 2 0 1 1 2 3 1 1 1 0 1 2 0 0 1 2 0 0 1 0 2 2 1 3 1 3 0 1 1 1 0 2 0 0 0 3 1 0 0 0 0 0 1 6 2 0 5 1 0 0 4 4 2 1 4 2 1 0 1 0 1 0 2 0 2 0 1 0 2 3 0 1 3 2 1 2 3 1 1 0 1 2 2 4 0 2 0 0 0 0 4 2 1 0 2 2 0 2 0 0 0 0 5 1 2 1 0 0 1 1 2 0 2 1 0 3 0 4 5 2 ...

output:

17710796705

result:

ok 1 number(s): "17710796705"

Test #103:

score: 0
Accepted
time: 278ms
memory: 37196kb

input:

140000 200000
0 1 0 0 0 1 0 4 0 0 0 0 1 2 13 0 0 1 0 0 2 0 0 1 0 6 1 0 1 0 7 2 3 0 1 0 0 5 1 0 1 0 0 1 1 1 0 0 1 1 3 1 0 0 3 1 0 1 2 0 1 1 0 0 0 2 2 0 0 0 5 1 0 1 6 2 1 0 0 0 1 1 1 0 1 2 1 0 0 3 0 0 0 0 4 7 0 0 1 2 1 0 1 0 0 1 0 1 1 0 8 1 0 1 0 0 1 3 0 0 3 0 0 0 1 2 1 0 0 2 1 0 9 1 1 0 4 1 0 1 1 1 1...

output:

18722320233

result:

ok 1 number(s): "18722320233"

Test #104:

score: 0
Accepted
time: 397ms
memory: 40144kb

input:

130000 200000
2 1 1 0 5 6 1 0 1 1 0 0 0 0 0 0 1 4 0 1 0 1 4 1 1 1 0 0 9 0 5 1 0 1 5 0 0 1 0 1 1 1 0 1 1 6 2 5 0 1 0 0 0 0 1 0 0 1 1 1 23 1 6 0 1 1 1 0 0 0 6 1 0 0 0 1 0 0 3 12 1 0 1 1 7 0 7 1 1 9 0 0 1 1 2 7 0 1 1 2 1 1 0 1 0 3 1 5 5 1 0 2 0 0 0 1 0 1 1 0 0 1 1 4 2 3 1 1 1 1 1 1 0 0 7 0 1 6 0 1 8 0 ...

output:

18887947123

result:

ok 1 number(s): "18887947123"

Test #105:

score: 0
Accepted
time: 614ms
memory: 39468kb

input:

120000 200000
1 1 4 0 17 8 1 0 0 1 7 4 1 25 32 0 0 22 1 1 0 1 3 16 0 0 0 0 0 0 0 0 0 1 0 1 0 1 0 8 0 1 0 0 1 0 1 0 7 0 1 1 0 0 0 0 0 6 1 18 0 3 1 0 0 3 1 0 0 0 1 0 0 0 1 1 1 0 0 0 1 0 1 0 0 0 0 3 0 0 6 0 1 1 0 1 1 0 3 0 1 0 0 5 0 5 6 1 1 0 1 0 0 0 1 1 1 0 0 13 1 9 4 1 1 0 0 0 0 0 11 1 16 0 0 0 0 0 0...

output:

18889893023

result:

ok 1 number(s): "18889893023"

Test #106:

score: 0
Accepted
time: 1210ms
memory: 41760kb

input:

110000 200000
1 0 1 0 1 3 0 1 1 0 1 94 0 0 1 0 1 2 1 0 1 0 0 5 0 0 1 0 1 0 6 1 1 1 0 11 1 0 0 1 0 0 1 0 0 0 1 15 0 1 1 0 0 1 0 1 0 11 1 0 0 0 0 0 1 37 0 0 0 0 0 1 0 1 0 1 1 0 0 1 1 0 28 0 0 0 1 1 0 1 1 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 3 1 21 0 0 0 0 0 1 0 0 0 12 1 1 0 1 1 0 1 1 0 9 10 1 0 4 1 0...

output:

18726901365

result:

ok 1 number(s): "18726901365"

Test #107:

score: 0
Accepted
time: 2075ms
memory: 39472kb

input:

105000 200000
1 0 1 0 1 1 0 0 0 0 0 1 0 0 1 0 12 1 1 1 0 0 0 0 1 0 1 1 1 0 0 0 1 1 0 0 1 0 1 1 0 0 0 1 1 0 52 1 0 0 0 0 1 0 0 0 0 0 1 0 1 1 0 0 0 0 1 0 0 1 1 0 0 1 1 0 0 0 0 1 0 1 1 6 1 0 0 0 0 0 1 0 0 1 1 0 1 0 0 0 0 0 0 0 0 1 19 0 0 0 0 1 0 0 1 0 0 1 0 1 0 16 1 2 0 1 0 0 1 1 0 0 1 0 0 1 1 0 0 1 1 ...

output:

18587746035

result:

ok 1 number(s): "18587746035"

Test #108:

score: 0
Accepted
time: 2373ms
memory: 41760kb

input:

104000 200000
0 1 1 1 1 0 0 0 0 1 1 1 0 54 0 1 0 0 1 1 0 0 1 0 1 0 1 8 0 0 0 1 1 1 0 0 93 0 1 0 0 0 0 1 0 1 1 0 0 1 0 0 0 1 0 1 1 1 1 1 1 0 0 0 1 0 0 0 0 0 1 1 0 1 0 0 1 1 1 0 1 1 0 1 0 1 1 1 0 1 1 0 1 0 1 1 1 1 0 1 0 1 0 0 1 1 1 0 1 0 1 0 1 0 1 0 0 0 1 0 1 1 1 0 1 0 0 1 1 1 1 0 0 0 0 0 1 1 0 1 0 0 ...

output:

18547998553

result:

ok 1 number(s): "18547998553"

Test #109:

score: 0
Accepted
time: 2758ms
memory: 39536kb

input:

103000 200000
0 1 0 0 0 0 0 1 1 1 0 0 0 1 0 0 0 0 0 0 1 1 1 0 0 1 1 0 0 0 0 0 1 0 0 1 1 0 0 0 0 0 0 1 1 0 0 0 1 0 1 0 1 1 0 0 1 0 1 0 1 1 1 1 0 0 0 27 0 1 0 0 0 0 1 1 1 24 0 0 0 0 1 4 0 0 64 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 1 0 1 1 0 0 0 1 0 0 1 1 0 0 1 1 1 1 1 0 0 1 0 0 1 1 1 0 1 1 1 1 0 1 1 0 1 0 0...

output:

18513858687

result:

ok 1 number(s): "18513858687"

Test #110:

score: 0
Accepted
time: 3230ms
memory: 39668kb

input:

102000 200000
1 1 0 1 0 0 1 0 0 0 1 0 0 1 1 0 1 0 0 0 1 26 1 0 0 127 0 0 0 0 0 1 0 1 1 1 0 1 1 0 1 1 0 0 1 0 0 0 0 0 1 0 1 1 0 1 0 0 0 1 1 0 1 0 0 0 1 0 1 1 1 0 0 0 1 1 0 0 0 1 0 0 1 1 0 0 0 0 0 1 0 0 1 0 1 1 1 0 0 1 0 1 0 0 0 0 1 0 0 0 1 0 1 0 0 1 1 1 1 0 1 1 0 0 0 0 1 1 1 0 0 1 0 1 0 0 1 0 0 1 0 1...

output:

18476252267

result:

ok 1 number(s): "18476252267"

Test #111:

score: 0
Accepted
time: 3974ms
memory: 39536kb

input:

101000 200000
1 0 0 0 1 0 0 1 1 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 1 245 1 0 1 0 1 0 0 1 1 1 1 1 0 1 0 1 0 0 1 1 0 1 0 0 1 1 0 0 1 278 0 0 1 1 1 0 0 0 0 1 1 1 0 1 1 0 1 0 0 1 1 1 1 1 0 0 1 1 0 1 1 1 0 1 0 30 1 1 0 0 1 0 0 0 0 0 0 0 0 1 1 0 1 1 0 1 1 0 0 1 0 0 0 1 1 1 1 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0...

output:

18439259353

result:

ok 1 number(s): "18439259353"

Test #112:

score: 0
Accepted
time: 95ms
memory: 36004kb

input:

180000 200000
2 0 2 0 0 1 1 0 2 1 2 0 0 2 2 2 3 1 2 3 1 2 1 0 2 0 0 1 1 0 2 0 2 2 0 2 2 1 0 2 2 0 0 0 1 0 1 2 2 1 2 2 2 0 1 2 1 2 0 2 1 2 0 1 0 0 0 2 1 2 2 0 1 2 1 2 2 0 1 0 1 0 2 1 1 1 1 0 1 0 2 1 1 2 1 2 1 1 2 2 2 3 2 0 3 2 1 3 0 3 1 0 2 0 0 2 1 3 0 1 2 1 1 2 0 1 0 2 1 0 0 0 2 0 0 0 2 2 0 2 0 1 2 ...

output:

16622983963

result:

ok 1 number(s): "16622983963"

Test #113:

score: 0
Accepted
time: 126ms
memory: 36172kb

input:

170000 200000
0 2 0 2 2 2 2 1 1 0 0 1 1 0 0 0 2 7 0 3 1 2 2 1 0 2 1 3 4 2 2 2 4 3 0 0 0 1 3 0 0 0 1 2 2 1 1 3 1 2 0 2 0 0 2 0 3 0 2 3 0 3 2 1 0 2 1 1 2 3 2 1 1 1 1 0 1 1 3 1 1 1 2 3 2 2 0 0 1 2 0 0 0 1 0 2 1 1 1 3 0 2 1 0 2 3 0 2 3 0 2 0 0 1 2 1 2 0 0 0 0 0 2 3 1 1 3 0 0 0 2 2 4 0 0 2 2 1 1 3 0 2 0 ...

output:

17848447615

result:

ok 1 number(s): "17848447615"

Test #114:

score: 0
Accepted
time: 239ms
memory: 39040kb

input:

150000 200000
1 1 1 2 0 1 0 0 4 0 0 0 2 1 6 1 1 5 0 2 0 1 3 1 0 0 0 0 1 1 0 0 4 0 1 1 0 0 0 1 1 0 0 1 1 1 3 0 4 2 1 0 1 0 1 0 4 1 0 0 1 3 1 0 0 0 4 2 1 7 3 0 0 3 0 2 1 5 1 0 0 1 2 1 0 0 1 0 0 0 1 2 0 3 0 1 2 1 0 0 1 5 0 4 4 2 2 0 2 1 0 1 2 1 0 1 1 2 0 0 0 2 1 2 11 1 5 2 4 1 5 0 1 2 0 1 0 1 0 2 0 0 1...

output:

19210442767

result:

ok 1 number(s): "19210442767"

Test #115:

score: 0
Accepted
time: 328ms
memory: 38548kb

input:

140000 200000
1 1 1 0 0 1 1 0 0 0 3 1 6 2 3 0 1 1 3 1 1 1 6 0 0 1 0 0 2 0 0 1 0 0 1 1 0 1 0 0 11 1 0 1 0 7 1 1 5 1 0 0 0 0 0 1 3 5 6 2 0 0 9 4 0 1 7 8 1 1 1 1 0 0 8 1 0 6 0 3 0 0 1 0 0 1 0 1 1 1 2 0 0 6 1 0 0 1 0 16 2 0 0 0 1 0 14 1 0 1 0 4 1 0 1 6 0 0 9 1 0 9 1 1 0 0 0 11 0 2 1 1 3 1 0 1 0 0 1 0 3 ...

output:

19541350693

result:

ok 1 number(s): "19541350693"

Test #116:

score: 0
Accepted
time: 542ms
memory: 40148kb

input:

130000 200000
1 0 0 1 1 11 24 2 1 0 2 0 0 1 0 1 21 0 1 1 1 0 1 1 0 0 0 0 0 1 0 1 1 1 2 1 1 0 0 0 1 1 3 1 1 1 0 1 1 0 8 0 3 1 1 0 1 0 2 1 11 0 1 0 0 0 0 0 0 0 0 1 15 2 1 1 0 0 4 1 0 1 0 11 1 1 0 0 4 1 1 1 0 0 5 6 14 0 1 1 0 6 8 2 1 1 1 0 0 1 0 0 9 2 1 0 1 1 1 0 0 1 0 0 0 0 0 0 1 0 1 2 0 1 1 1 0 0 1 0...

output:

19695497145

result:

ok 1 number(s): "19695497145"

Test #117:

score: 0
Accepted
time: 1070ms
memory: 38524kb

input:

120000 200000
0 1 0 1 1 1 1 1 0 0 0 14 0 0 8 13 0 0 0 1 0 0 0 1 0 0 0 1 0 1 1 1 0 0 1 0 1 7 1 0 1 1 0 1 1 0 1 0 0 0 0 1 1 0 1 1 1 0 0 0 0 1 1 0 0 1 0 1 0 0 0 1 0 0 0 1 1 1 1 20 1 0 0 0 0 0 0 0 25 0 1 0 0 0 0 1 1 18 0 0 1 0 1 0 0 19 0 0 1 0 1 0 1 1 0 1 0 0 0 1 1 0 1 0 18 0 0 1 1 1 1 0 2 1 0 0 0 0 0 0...

output:

19676384775

result:

ok 1 number(s): "19676384775"

Test #118:

score: 0
Accepted
time: 1822ms
memory: 40968kb

input:

115000 200000
0 1 0 0 1 1 1 0 0 1 0 0 0 1 1 0 1 10 0 1 0 1 0 0 0 1 1 1 0 1 1 0 1 0 0 1 1 0 0 1 0 0 0 1 1 0 0 1 0 1 1 0 0 0 1 0 0 0 1 0 1 31 1 0 0 0 1 0 0 0 0 0 18 1 0 1 1 0 1 0 1 0 0 0 1 0 0 0 1 0 0 0 0 0 1 0 0 1 0 0 1 0 0 0 0 0 0 1 0 0 1 0 0 1 1 1 0 0 0 0 1 1 1 0 1 51 1 0 0 0 1 0 1 1 1 1 6 0 0 1 0 ...

output:

19604022905

result:

ok 1 number(s): "19604022905"

Test #119:

score: 0
Accepted
time: 2100ms
memory: 41632kb

input:

114000 200000
0 1 1 1 1 1 0 0 0 0 0 0 0 0 1 1 1 1 0 1 1 0 1 0 0 0 1 0 0 1 0 1 0 0 0 0 1 0 1 1 1 0 1 0 1 0 1 0 1 1 0 0 1 0 12 1 0 0 36 2 1 0 0 0 1 1 0 1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 1 0 0 1 1 1 1 0 1 0 1 1 1 0 1 0 1 0 0 0 1 1 13 0 1 1 1 1 1 1 0 0 0 0 39 1 0 0 0 1 1 1 0 0 0 1 0 0 1 1 0 1 1 1 0 0 1 0 1 ...

output:

19584002611

result:

ok 1 number(s): "19584002611"

Test #120:

score: 0
Accepted
time: 2467ms
memory: 41172kb

input:

113000 200000
0 0 0 0 0 1 1 1 1 0 1 1 1 0 0 0 1 1 1 1 1 0 1 1 0 1 0 1 1 1 0 0 0 0 0 0 1 0 1 1 0 1 1 0 1 1 0 1 1 1 0 1 1 0 0 1 0 0 0 1 1 0 0 1 1 0 1 0 0 1 0 1 0 0 0 0 0 0 0 0 6 32 0 1 1 0 1 0 0 1 0 0 0 1 1 1 0 1 0 0 1 0 1 1 0 1 1 0 0 1 1 0 0 1 0 0 0 0 0 1 1 1 1 0 1 1 0 1 1 1 1 1 0 1 0 1 1 1 1 0 0 1 0...

output:

19565883951

result:

ok 1 number(s): "19565883951"

Test #121:

score: 0
Accepted
time: 2899ms
memory: 41260kb

input:

112000 200000
1 0 1 0 0 0 0 0 0 0 0 1 1 1 1 0 0 1 1 0 1 0 1 0 0 1 1 1 0 1 0 1 0 0 1 0 0 1 0 1 3 0 0 0 1 1 1 0 1 50 1 0 0 0 0 0 0 1 0 1 1 1 0 0 0 1 1 0 1 1 0 0 0 1 0 0 0 1 11 1 0 0 0 1 1 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 1 0 1 0 1 1 1 0 1 0 0 1 0 1 1 1 1 1 1 0 0 0 0 1 0 1 0 0 0 0 0 1 0 0 ...

output:

19546111275

result:

ok 1 number(s): "19546111275"

Test #122:

score: 0
Accepted
time: 3554ms
memory: 38832kb

input:

111000 200000
0 1 0 1 0 1 1 0 1 0 0 0 0 1 0 0 1 0 1 0 0 1 1 0 1 0 0 1 0 0 0 0 1 0 1 0 1 1 1 1 1 1 0 0 0 1 0 1 0 1 139 0 0 1 1 1 1 0 0 0 1 0 0 0 0 1 1 0 0 0 1 0 0 1 0 0 1 1 1 1 0 1 0 0 0 0 193 0 1 1 0 1 1 1 0 0 1 1 0 1 0 1 1 0 0 0 0 1 1 0 1 1 1 1 0 0 0 0 0 1 1 1 0 1 1 1 0 1 1 0 0 0 1 1 0 0 0 0 0 0 0 ...

output:

19524369297

result:

ok 1 number(s): "19524369297"

Test #123:

score: 0
Accepted
time: 3593ms
memory: 34912kb

input:

41000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 24 1 1 90 118 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 35 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 850 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 153 1 1 1 37 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 6 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6440443909

result:

ok 1 number(s): "6440443909"

Test #124:

score: 0
Accepted
time: 2967ms
memory: 33556kb

input:

42000 200000
1 1 1 1 1 1 1 1 1 43 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 120 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 188 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 254 168 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 70 1 1 1 1 1 1 1 249 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6473218113

result:

ok 1 number(s): "6473218113"

Test #125:

score: 0
Accepted
time: 2135ms
memory: 34680kb

input:

44000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 11 7 1 1 1 1 1 1 53 1 90 1 1 1 12 1 1 1 1 1 1 1 1 15 1 120 1 1 1 1 3 1 1 1 1 1 1 1 1 1 1 1 1 10 1 1 1 1 42 1 1 62 1 1 1 1 1 1 1 1 1 53 1 16 3 1 1 1 1 1 1 1 1 1 1 1 1 1 1 8 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6541045667

result:

ok 1 number(s): "6541045667"

Test #126:

score: 0
Accepted
time: 1247ms
memory: 33444kb

input:

48000 200000
1 109 18 1 1 1 1 1 1 1 1 1 1 1 1 1 1 22 16 1 1 6 1 1 1 1 1 1 1 1 1 1 23 3 1 1 1 1 1 1 1 1 4 1 59 1 1 1 17 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 26 3 12 1 1 1 37 1 1 1 21 1 1 1 1 1 1 1 1 1 1 1 62 1 1 1 9 1 5 1 1 1 1 1 1 1 1 1 1 5 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 21 1 1 1 1 1 1 1...

output:

6639623735

result:

ok 1 number(s): "6639623735"

Test #127:

score: 0
Accepted
time: 562ms
memory: 34116kb

input:

56000 200000
1 1 1 20 1 1 1 1 1 1 1 13 1 1 1 3 1 1 1 1 1 1 1 1 3 1 1 5 1 1 1 1 1 4 1 1 14 1 1 1 1 1 1 1 23 1 1 1 1 1 1 7 1 1 1 1 1 1 1 1 16 3 1 1 1 1 1 1 23 5 1 1 1 1 21 1 1 1 1 1 40 1 1 3 1 5 1 9 7 1 1 1 1 1 1 1 18 1 14 9 1 9 1 5 1 1 1 1 1 5 1 1 1 4 9 1 4 1 5 1 1 5 1 1 1 12 1 1 1 6 1 10 1 1 1 6 1 6...

output:

6706407213

result:

ok 1 number(s): "6706407213"

Test #128:

score: 0
Accepted
time: 176ms
memory: 32004kb

input:

72000 200000
4 4 1 1 1 5 1 1 1 1 1 1 1 6 1 1 1 1 1 1 3 1 1 4 1 5 1 1 1 9 1 1 1 1 1 1 6 4 1 1 3 1 7 1 3 1 21 1 1 1 7 1 1 1 1 4 1 3 1 4 1 13 3 1 3 1 1 6 1 1 3 1 3 1 1 9 4 6 1 3 7 3 1 1 1 1 3 1 1 1 3 1 5 4 1 3 1 1 4 1 3 1 8 1 4 1 3 3 5 5 4 1 1 1 8 1 1 1 1 1 3 1 3 1 3 1 6 1 1 1 1 5 4 6 3 3 4 1 4 4 1 1 6...

output:

6348977609

result:

ok 1 number(s): "6348977609"

Test #129:

score: 0
Accepted
time: 33ms
memory: 28928kb

input:

90000 200000
1 1 3 1 1 1 3 1 3 3 5 3 4 1 1 1 1 1 3 3 1 3 1 3 1 1 1 3 1 3 3 3 3 1 1 3 3 3 4 1 1 3 1 3 1 1 1 1 3 3 3 1 3 1 1 1 3 3 3 1 3 4 1 1 3 3 1 5 1 3 3 1 1 4 1 3 3 4 3 1 3 1 1 1 3 3 1 1 4 1 3 3 3 3 3 3 1 3 1 1 1 1 3 1 3 3 3 3 1 4 1 3 3 3 3 1 4 3 1 3 3 3 3 1 3 1 3 3 3 1 3 1 1 4 1 1 3 3 4 1 1 3 1 3...

output:

4828716105

result:

ok 1 number(s): "4828716105"

Test #130:

score: 0
Accepted
time: 3525ms
memory: 33584kb

input:

41000 200000
32 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 39 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 27 1 1 1 1 1 1 1 43 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 14 ...

output:

6437142047

result:

ok 1 number(s): "6437142047"

Test #131:

score: 0
Accepted
time: 2929ms
memory: 33424kb

input:

42000 200000
1 1 1 1 1 1 23 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 17 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 43 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 97 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6470681159

result:

ok 1 number(s): "6470681159"

Test #132:

score: 0
Accepted
time: 2035ms
memory: 34680kb

input:

44000 200000
24 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 23 1 1 1 1 1 1 1 1 1 5 1 1 11 1 1 1 1 1 25 96 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 39 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 15 1 1 1 1 25 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 46 1 1 118 1 1 1 20 1 1 1 22 1 1 1 1 35 1 19 1 10 1 1 1 1 1 1 1 1...

output:

6522954181

result:

ok 1 number(s): "6522954181"

Test #133:

score: 0
Accepted
time: 1066ms
memory: 34776kb

input:

48000 200000
11 1 1 1 5 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 11 26 11 1 1 1 1 1 12 1 1 1 1 9 1 43 1 1 1 1 1 9 7 1 1 1 1 1 11 1 1 1 1 6 1 1 1 1 1 1 1 1 1 1 1 1 17 18 28 1 1 1 1 1 1 1 44 1 1 17 1 25 1 1 1 5 1 1 1 1 1 1 7 1 1 1 1 1 32 26 1 1 1 1 1 1 1 1 1 1 1 1 19 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6575984667

result:

ok 1 number(s): "6575984667"

Test #134:

score: 0
Accepted
time: 390ms
memory: 35704kb

input:

56000 200000
8 1 1 1 1 1 1 1 1 20 1 1 1 1 1 1 15 1 1 1 1 1 1 1 1 1 1 5 11 1 1 6 1 17 1 8 15 5 1 9 1 1 1 1 1 1 1 1 1 1 15 11 1 8 13 9 1 1 9 1 1 1 14 1 9 1 1 1 1 9 1 1 1 1 1 1 1 1 1 7 5 1 9 1 1 1 1 1 1 1 7 9 1 1 1 1 27 1 7 1 15 1 1 1 1 1 6 1 1 1 5 1 1 7 1 1 1 1 15 1 13 6 1 1 1 14 13 1 1 1 1 1 1 1 1 13...

output:

6459988515

result:

ok 1 number(s): "6459988515"

Test #135:

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

input:

72000 200000
1 5 1 1 1 5 5 5 5 1 5 5 1 5 5 5 5 5 5 1 1 1 1 1 5 1 1 5 5 5 5 5 1 5 5 5 5 1 5 1 1 5 1 1 1 1 1 5 1 5 5 1 1 1 1 1 5 5 1 1 5 1 5 5 1 5 1 5 5 5 5 5 5 1 1 1 1 5 1 1 1 5 1 1 1 1 5 1 1 5 1 1 1 5 5 5 1 1 1 5 5 1 1 1 1 1 1 5 5 5 5 1 5 5 5 5 1 1 1 1 1 1 5 1 5 1 1 1 1 5 5 1 1 1 1 1 5 5 5 1 1 1 1 5...

output:

1280072001

result:

ok 1 number(s): "1280072001"

Test #136:

score: 0
Accepted
time: 3478ms
memory: 33496kb

input:

41000 200000
1 1 1 68 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 157 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6436544675

result:

ok 1 number(s): "6436544675"

Test #137:

score: 0
Accepted
time: 2852ms
memory: 33556kb

input:

42000 200000
1 1 1 1 1 17 1 1 1 1 1 1 1 1 1 1 1 1 235 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 66 1 59 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 82 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 22 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6464518453

result:

ok 1 number(s): "6464518453"

Test #138:

score: 0
Accepted
time: 1881ms
memory: 34764kb

input:

44000 200000
1 1 1 9 1 1 1 1 64 1 1 1 1 1 1 1 1 1 1 1 1 1 1 29 99 14 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 29 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 68 1 1 1 1 31 1 1 1 1 1 1 1 1 1 24 1 1 1 1 1 13 1 1 1 1 1 1 1 1 1 1 1 1 1 22 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 49 1 1 1 1 1 1 ...

output:

6502429111

result:

ok 1 number(s): "6502429111"

Test #139:

score: 0
Accepted
time: 833ms
memory: 33132kb

input:

48000 200000
1 1 1 1 1 1 22 68 1 40 1 1 1 1 1 1 1 1 41 13 1 1 1 1 32 1 27 1 1 25 1 1 1 46 1 1 1 1 1 1 1 19 1 1 1 1 1 18 18 10 46 1 26 1 1 1 1 1 1 1 1 9 22 1 1 1 1 1 1 17 29 1 1 15 1 1 1 12 1 1 1 29 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 19 11 1 26 24 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 8 1 1 1 9 1 1 1 1 1 12 1...

output:

6475746645

result:

ok 1 number(s): "6475746645"

Test #140:

score: 0
Accepted
time: 162ms
memory: 33420kb

input:

56000 200000
1 1 9 1 1 1 1 1 1 1 1 1 9 12 8 1 1 1 1 1 1 8 1 1 13 1 12 1 1 1 1 1 1 1 1 1 1 1 1 8 1 8 1 1 1 1 1 1 1 1 8 1 1 9 1 1 1 9 14 11 10 1 1 9 1 1 1 8 1 9 9 8 1 1 1 1 1 1 1 1 1 1 1 1 1 9 1 1 1 1 1 1 1 1 1 9 12 1 1 1 1 1 1 8 1 22 1 1 1 8 8 1 10 12 1 1 8 8 9 1 11 1 1 1 1 1 11 1 1 12 1 1 1 1 9 9 8 ...

output:

6066581825

result:

ok 1 number(s): "6066581825"

Test #141:

score: 0
Accepted
time: 15ms
memory: 28036kb

input:

60000 200000
1 1 1 1 1 1 1 1 8 8 8 8 1 1 1 8 8 1 8 1 8 1 8 1 1 8 1 1 8 1 1 1 1 1 1 1 1 1 1 1 1 8 1 1 1 1 8 1 8 1 8 1 1 8 1 1 1 8 1 8 1 8 8 1 1 8 8 8 1 1 8 1 1 1 1 1 8 8 1 1 1 1 8 1 1 1 1 1 8 1 1 8 1 8 8 1 1 8 8 1 8 8 8 1 1 8 1 8 1 1 1 8 1 1 1 1 1 8 1 8 1 1 1 8 1 8 8 8 8 1 1 8 1 8 1 1 8 1 1 1 1 1 8 1...

output:

800060001

result:

ok 1 number(s): "800060001"

Test #142:

score: 0
Accepted
time: 3521ms
memory: 36424kb

input:

41000 200000
1 1 1 1 1 1 52 1 1 1 1 1 1 1 1 50 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 20 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 95 1 1 39 1 1 470 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 79 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6436102759

result:

ok 1 number(s): "6436102759"

Test #143:

score: 0
Accepted
time: 2857ms
memory: 35900kb

input:

42000 200000
1 1 1 1 1 125 1 1 1 1 1 1 1 1 1 1 1 1 1 1 219 1 1 1 1 1 1 1 1 1 1 18 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 35 1 1 1 1 1 1 1 1 1 1 1 1 1 25 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6462518649

result:

ok 1 number(s): "6462518649"

Test #144:

score: 0
Accepted
time: 1736ms
memory: 34700kb

input:

44000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 11 1 1 1 1 1 1 1 76 1 1 11 1 1 34 1 1 1 42 1 1 1 1 1 1 1 54 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 16 1 1 1 1 1 1 1 1 1 1 1 1 26 1 1 1 1 1 1 1 1 1 1 1 37 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 44 1 1 1 1 1 1 58 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6483860949

result:

ok 1 number(s): "6483860949"

Test #145:

score: 0
Accepted
time: 681ms
memory: 34460kb

input:

48000 200000
1 1 26 1 18 30 1 1 1 1 1 1 1 1 1 35 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 24 1 1 13 1 1 1 1 1 1 1 1 1 1 1 1 1 1 38 1 17 1 1 1 24 1 1 1 1 1 1 16 1 1 1 1 1 1 1 1 1 1 13 11 16 1 1 1 1 1 1 1 19 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 11 1 19 17 1 1 1 1 1 1 1 1 1 1 1 1 15 17 1 1 32 1 1 1 1 1 1...

output:

6413030053

result:

ok 1 number(s): "6413030053"

Test #146:

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

input:

56000 200000
1 1 10 1 1 1 1 1 10 1 1 10 10 10 10 1 1 1 1 1 1 10 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 10 10 1 1 1 1 10 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 10 1 1 10 10 1 10 1 10 1 1 1 1 1 1 1 1 1 1 10 10 1 10 1 1 1 1 1 1 1 1 10 10 1 1 10 1 1 1 1 10 10 1 10 1 10 10 1 1 1 1 10 1 1 1 1 1 1 1 1 10 10 10 1 10 1 10 1...

output:

640056001

result:

ok 1 number(s): "640056001"

Test #147:

score: 0
Accepted
time: 3297ms
memory: 33496kb

input:

41000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 83 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 81 1 1 1 1 1 1 1 1 1 1 1 1 1 201 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6430840205

result:

ok 1 number(s): "6430840205"

Test #148:

score: 0
Accepted
time: 2461ms
memory: 33560kb

input:

42000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 145 1 1 1 1 29 62 1 1 49 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 104 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 101 1 1 1 1 31 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6439145653

result:

ok 1 number(s): "6439145653"

Test #149:

score: 0
Accepted
time: 1140ms
memory: 35008kb

input:

44000 200000
1 1 1 1 31 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 24 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 36 39 1 1 1 1 1 1 1 1 69 1 1 1 1 1 20 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 99 1 1 1 30 1 1 1 1 1 1 1 1 1 1 34 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 47 1 1 1 1...

output:

6402250993

result:

ok 1 number(s): "6402250993"

Test #150:

score: 0
Accepted
time: 16ms
memory: 30884kb

input:

48000 200000
1 1 20 20 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 20 1 1 1 1 20 1 1 1 1 1 1 1 1 1 1 1 1 1 20 1 20 1 1 1 20 20 1 1 1 1 1 1 1 1 1 1 20 20 20 1 1 20 1 1 1 1 20 1 1 20 1 1 1 1 1 20 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 20 1 20 1 1 1 1 1 20 20 1 1 1 1 1 1 20 20 1 20 1 20 20 1 1 20 1 1 1 ...

output:

320048001

result:

ok 1 number(s): "320048001"

Test #151:

score: 0
Accepted
time: 3002ms
memory: 36016kb

input:

41000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 51 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 232 1 1 1 1 184 1 1 1 1 1 1 1 1 1 1 1 1 1 1 100 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6416444385

result:

ok 1 number(s): "6416444385"

Test #152:

score: 0
Accepted
time: 1705ms
memory: 35140kb

input:

42000 200000
80 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 110 1 1 1 1 1 1 1 1 1 1 1 1 104 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 86 1 1 57 57 1 1 1 1 1 1 1 1 49 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 42 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6396825195

result:

ok 1 number(s): "6396825195"

Test #153:

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

input:

44000 200000
1 40 1 1 1 1 1 1 1 1 1 40 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 40 1 1 1 1 1 1 40 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 40 40 1 1 1 40 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 40 1 40 1 1 1 1 1 1 1 40 1 1 40 1 1 1 1 1 1 1 1 40 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

160044001

result:

ok 1 number(s): "160044001"

Test #154:

score: 0
Accepted
time: 2081ms
memory: 34828kb

input:

41000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 231 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 173 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6392246101

result:

ok 1 number(s): "6392246101"

Test #155:

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

input:

42000 200000
1 1 1 1 1 1 1 1 1 1 1 80 1 1 1 1 1 1 1 1 1 1 1 1 1 80 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 80 80 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 80 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 80 1 80 80 1 1 1 1 1...

output:

80042001

result:

ok 1 number(s): "80042001"

Test #156:

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

input:

41000 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 160 1 1 1 1 1 1 1 160 160 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

40041001

result:

ok 1 number(s): "40041001"

Test #157:

score: 0
Accepted
time: 720ms
memory: 34800kb

input:

40140 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1036 1 ...

output:

6238834167

result:

ok 1 number(s): "6238834167"

Test #158:

score: 0
Accepted
time: 832ms
memory: 35996kb

input:

40120 200000
1 1 1 1 1 1 1 1611 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1083 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

6242533691

result:

ok 1 number(s): "6242533691"

Test #159:

score: 0
Accepted
time: 578ms
memory: 36052kb

input:

40070 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 3933 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

6178767437

result:

ok 1 number(s): "6178767437"

Test #160:

score: 0
Accepted
time: 299ms
memory: 36220kb

input:

40040 200000
1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1...

output:

5986029709

result:

ok 1 number(s): "5986029709"

Test #161:

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

input:

109 100
2 0 1 1 0 1 0 0 0 1 2 2 1 4 0 5 1 1 1 1 2 0 0 0 0 1 0 0 0 1 2 5 1 1 0 4 3 0 1 1 2 1 0 0 5 2 1 0 0 0 1 0 0 1 0 1 1 1 0 1 1 1 0 0 1 0 0 0 1 1 0 0 0 1 0 3 2 1 1 1 1 0 0 0 1 1 1 0 0 0 1 2 0 1 1 1 1 0 0 1 0 0 4 1 0 1 3 1 1

output:

6464

result:

ok 1 number(s): "6464"

Test #162:

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

input:

153 100
1 1 1 1 1 1 1 1 1 0 1 1 1 0 2 1 1 1 0 1 0 1 0 0 1 1 1 0 1 0 3 0 1 1 1 1 0 1 0 0 1 1 0 1 1 0 0 0 0 0 1 0 1 0 1 1 0 1 1 1 1 0 0 1 1 0 0 1 1 1 0 1 1 0 0 0 0 0 0 1 1 1 0 0 1 1 1 1 0 1 1 1 1 1 0 0 0 2 1 0 1 0 0 1 0 1 1 0 0 0 0 1 3 1 1 0 1 0 1 0 1 1 1 0 1 0 1 1 0 1 0 1 1 1 0 0 1 1 0 1 2 0 1 1 0 0 ...

output:

7128

result:

ok 1 number(s): "7128"

Test #163:

score: 0
Accepted
time: 1128ms
memory: 39096kb

input:

94279 200000
0 1 1 1 1 0 1 0 0 0 1 1 1 1 1 0 1 1 1 1 0 1 3 1 1 0 0 1 1 1 1 0 1 0 1 28 1 1 1 0 5 50 2 0 1 1 0 1 1 0 0 0 0 1 0 1 1 0 1 7 1 6 0 0 1 0 1 0 0 0 1 3 1 1 1 0 0 1 0 0 1 0 1 0 1 1 9 1 1 0 0 0 0 1 1 4 1 1 1 0 1 1 1 0 17 0 1 0 0 0 1 0 0 0 1 0 23 0 0 1 6 1 0 1 0 0 0 26 1 1 1 0 0 1 36 0 1 24 2 0 ...

output:

15069119526

result:

ok 1 number(s): "15069119526"

Test #164:

score: 0
Accepted
time: 1261ms
memory: 39188kb

input:

92230 200000
1 0 1 1 1 0 1 0 0 0 0 1 1 1 1 89 0 6 0 19 1 1 1 1 1 0 1 1 5 1 1 1 0 2 0 1 0 0 0 0 0 1 1 4 0 1 0 1 1 1 1 1 1 1 1 1 1 0 0 0 1 1 1 1 0 1 1 0 1 1 1 0 1 1 0 0 1 0 1 1 0 0 0 1 65 0 0 1 1 1 1 1 1 1 0 1 1 0 1 1 0 0 1 1 27 1 1 0 1 0 0 28 1 1 33 1 1 0 1 0 1 0 5 1 1 0 1 0 0 1 0 1 0 1 1 0 1 0 0 1 1...

output:

14696873705

result:

ok 1 number(s): "14696873705"