QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#422376#8726. Magic Showqwqer233100 ✓1ms1880kbC++201.8kb2024-05-27 13:24:212024-05-27 13:24:22

Judging History

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

  • [2024-05-27 13:24:22]
  • 评测
  • 测评结果:100
  • 用时:1ms
  • 内存:1880kb
  • [2024-05-27 13:24:21]
  • 提交

Alice

#include<bits/stdc++.h>
using namespace std;
#include "Alice.h"
#define ll long long
#define pb emplace_back
#define pii pair<int,int>
#define P 101

ll qpow(ll x,ll y=P-2){
	ll z=1;while(y){
		if(y&1) z=z*x%P;
		x=x*x%P,y>>=1;
	}
	return z;
}
ll a[9];
ll f(ll x){
	ll ret=0;
	for(ll i=0;i<=8;i++){
		(ret+=a[i]*qpow(x,i))%=P;
	}
	return ret;
}
vector<pair<int,int>> Alice(){
	ll x=setN(4901);x--;
	ll i,j;
	for(i=0;i<=8;i++) a[i]=x%100,x/=100;
	vector<pii> ret;
	for(i=1;i<=49;i++){
		ll d=f(i);
		for(j=0;j<=100;j++){
			if(d!=j) ret.pb(100*i-99+d,100*i-99+j);
		}
	}
	return ret;
}

Bob

#include<bits/stdc++.h>
using namespace std;
#include "Bob.h"
#define ll long long
#define pb emplace_back
#define pii pair<int,int>
#define fi first
#define se second
#define P 101

#define a QWQ__TAT
ll aa[22],d[5005];
vector<pii> v;
ll ans;
#define B 8
ll fpow(ll x,ll y=P-2){
	ll z=1;while(y){
		if(y&1) z=z*x%P;
		x=x*x%P,y>>=1;
	}
	return z;
}
void solve(){
	// v.resize(B+1);
	// for(auto [p,q]:v) cerr<<p<<' '<<q<<endl;
	ll i,j;
	for(i=0;i<=B;i++){
		ll a1=v[i].se;
		for(j=0;j<=B;j++){
			if(i!=j) a1=a1*fpow(v[i].fi-v[j].fi)%P;
		}
		a1=(a1+P)%P;
		for(j=0;j<(1<<(B+1));j++){
			if(j&(1<<i)) continue;
			ll a2=1;
			for(ll k=0;k<=B;k++){
				if(j&(1<<k)) a2=a2*(P-v[k].fi)%P;
			}
			(aa[B-__builtin_popcount(j)]+=a1*a2)%=P;
		}
		// cerr<<"aa: ";for(j=0;j<=B;j++) cerr<<aa[j]<<' ';cerr<<endl;
	}
	for(i=B;i>=0;i--) ans=ans*100+aa[i];
}
ll Bob(vector<pair<int,int>> V){
	ll i,j;
	for(i=1;i<=49;i++){
		int L=100*i-99,R=100*i+1;
		for(j=L;j<=R;j++) d[j]=0;
		for(auto [p,q]:V) if(L<=p&&p<=R&&L<=q&&q<=R) d[p]++,d[q]++;
		for(j=0;j<=100;j++){
			if(d[100*i-99+j]>=2) v.pb(i,j);
		}
	}
	v.resize(9);
	solve();
	return ans+1;
}

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 5
Accepted

Test #1:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1872kb,1860kb

input:

1
4005

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
45 1
45 2
45 3
45 4
45 5
45 6
45 7
45 8
45 9
45 10
45 11
45 12
45 13
45 14
45 15
45 16
45 17
45 18
45 19
45 20
45 21
45 22
45 23
45 24
45 25
45 26
45 27
45 28
45 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
45 1
45 2
45 3
45 4
45 5
45 6
45 7
45 8
45 9
45 10
45 11
45 12
45 13
45 14
45 15
45 16
45 17
45 18
45 19
45 20
45 21
45 22
45 23
45 24
45 25
45 26
45 27
45 28
45 29...

output:

2
4901 3418
1 45
2 45
3 45
4 45
5 45
6 45
7 45
8 45
9 45
11 45
12 45
14 45
15 45
16 45
17 45
18 45
20 45
21 45
22 45
23 45
24 45
25 45
26 45
28 45
29 45
30 45
31 45
33 45
34 45
35 45
36 45
39 45
40 45
41 45
43 45
44 45
45 46
45 47
45 48
45 49
45 51
45 54
45 55
45 56
45 59
45 60
45 61
45 62
45 64
45 ...

input:

2
4901 3418
1 45
2 45
3 45
4 45
5 45
6 45
7 45
8 45
9 45
11 45
12 45
14 45
15 45
16 45
17 45
18 45
20 45
21 45
22 45
23 45
24 45
25 45
26 45
28 45
29 45
30 45
31 45
33 45
34 45
35 45
36 45
39 45
40 45
41 45
43 45
44 45
45 46
45 47
45 48
45 49
45 51
45 54
45 55
45 56
45 59
45 60
45 61
45 62
45 64
45 ...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
4005

Test #2:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1860kb

input:

1
459

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
63 1
63 2
63 3
63 4
63 5
63 6
63 7
63 8
63 9
63 10
63 11
63 12
63 13
63 14
63 15
63 16
63 17
63 18
63 19
63 20
63 21
63 22
63 23
63 24
63 25
63 26
63 27
63 28
63 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
63 1
63 2
63 3
63 4
63 5
63 6
63 7
63 8
63 9
63 10
63 11
63 12
63 13
63 14
63 15
63 16
63 17
63 18
63 19
63 20
63 21
63 22
63 23
63 24
63 25
63 26
63 27
63 28
63 29...

output:

2
4901 3418
1 63
2 63
3 63
4 63
5 63
6 63
7 63
8 63
9 63
11 63
12 63
14 63
15 63
16 63
17 63
18 63
20 63
21 63
22 63
23 63
24 63
25 63
26 63
28 63
29 63
30 63
31 63
33 63
34 63
35 63
36 63
39 63
40 63
41 63
43 63
44 63
45 63
46 63
47 63
48 63
50 63
53 63
54 63
55 63
58 63
59 63
60 63
61 63
63 64
63 ...

input:

2
4901 3418
1 63
2 63
3 63
4 63
5 63
6 63
7 63
8 63
9 63
11 63
12 63
14 63
15 63
16 63
17 63
18 63
20 63
21 63
22 63
23 63
24 63
25 63
26 63
28 63
29 63
30 63
31 63
33 63
34 63
35 63
36 63
39 63
40 63
41 63
43 63
44 63
45 63
46 63
47 63
48 63
50 63
53 63
54 63
55 63
58 63
59 63
60 63
61 63
63 64
63 ...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
459

Test #3:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1856kb

input:

1
2495

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

output:

2
4901 3418
1 18
2 18
3 18
4 18
5 18
6 18
7 18
8 18
9 18
11 18
12 18
14 18
15 18
16 18
17 18
18 19
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 29
18 30
18 31
18 32
18 34
18 35
18 36
18 37
18 40
18 41
18 42
18 44
18 45
18 46
18 47
18 48
18 49
18 51
18 54
18 55
18 56
18 59
18 60
18 61
18 62
18 64
18 ...

input:

2
4901 3418
1 18
2 18
3 18
4 18
5 18
6 18
7 18
8 18
9 18
11 18
12 18
14 18
15 18
16 18
17 18
18 19
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 29
18 30
18 31
18 32
18 34
18 35
18 36
18 37
18 40
18 41
18 42
18 44
18 45
18 46
18 47
18 48
18 49
18 51
18 54
18 55
18 56
18 59
18 60
18 61
18 62
18 64
18 ...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
2495

Test #4:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1844kb

input:

3
1560

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
75 1
75 2
75 3
75 4
75 5
75 6
75 7
75 8
75 9
75 10
75 11
75 12
75 13
75 14
75 15
75 16
75 17
75 18
75 19
75 20
75 21
75 22
75 23
75 24
75 25
75 26
75 27
75 28
75 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
75 1
75 2
75 3
75 4
75 5
75 6
75 7
75 8
75 9
75 10
75 11
75 12
75 13
75 14
75 15
75 16
75 17
75 18
75 19
75 20
75 21
75 22
75 23
75 24
75 25
75 26
75 27
75 28
75 29...

output:

4
4901 2451
1301 1368
1302 1368
1303 1368
1304 1368
1305 1368
1306 1368
1307 1368
1308 1368
1309 1368
1310 1368
1311 1368
1312 1368
1313 1368
1314 1368
1315 1368
1316 1368
1317 1368
1318 1368
1319 1368
1320 1368
1321 1368
1322 1368
1323 1368
1324 1368
1325 1368
1326 1368
1327 1368
1328 1368
1329 136...

input:

4
4901 2451
1301 1368
1302 1368
1303 1368
1304 1368
1305 1368
1306 1368
1307 1368
1308 1368
1309 1368
1310 1368
1311 1368
1312 1368
1313 1368
1314 1368
1315 1368
1316 1368
1317 1368
1318 1368
1319 1368
1320 1368
1321 1368
1322 1368
1323 1368
1324 1368
1325 1368
1326 1368
1327 1368
1328 1368
1329 136...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
1560

Test #5:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1844kb

input:

3
3594

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
28 1
28 2
28 3
28 4
28 5
28 6
28 7
28 8
28 9
28 10
28 11
28 12
28 13
28 14
28 15
28 16
28 17
28 18
28 19
28 20
28 21
28 22
28 23
28 24
28 25
28 26
28 27
28 29
28 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
28 1
28 2
28 3
28 4
28 5
28 6
28 7
28 8
28 9
28 10
28 11
28 12
28 13
28 14
28 15
28 16
28 17
28 18
28 19
28 20
28 21
28 22
28 23
28 24
28 25
28 26
28 27
28 29
28 30...

output:

4
4901 2451
467 501
501 502
501 503
501 504
501 505
501 506
501 507
501 508
501 509
501 510
501 511
501 512
501 513
501 514
501 515
501 516
501 517
501 518
501 519
501 520
501 521
501 522
501 523
501 524
501 525
501 526
501 527
501 528
501 529
501 530
501 531
501 532
501 533
501 534
501 535
501 536
...

input:

4
4901 2451
467 501
501 502
501 503
501 504
501 505
501 506
501 507
501 508
501 509
501 510
501 511
501 512
501 513
501 514
501 515
501 516
501 517
501 518
501 519
501 520
501 521
501 522
501 523
501 524
501 525
501 526
501 527
501 528
501 529
501 530
501 531
501 532
501 533
501 534
501 535
501 536
...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
3594

Test #6:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1840kb

input:

3
1750

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
67 1
67 2
67 3
67 4
67 5
67 6
67 7
67 8
67 9
67 10
67 11
67 12
67 13
67 14
67 15
67 16
67 17
67 18
67 19
67 20
67 21
67 22
67 23
67 24
67 25
67 26
67 27
67 28
67 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
67 1
67 2
67 3
67 4
67 5
67 6
67 7
67 8
67 9
67 10
67 11
67 12
67 13
67 14
67 15
67 16
67 17
67 18
67 19
67 20
67 21
67 22
67 23
67 24
67 25
67 26
67 27
67 28
67 29...

output:

4
4901 2451
201 301
202 301
203 301
204 301
205 301
206 301
207 301
208 301
209 301
210 301
211 301
212 301
213 301
214 301
215 301
216 301
217 301
218 301
219 301
220 301
221 301
222 301
223 301
224 301
225 301
226 301
227 301
228 301
229 301
230 301
231 301
232 301
233 301
234 301
235 301
236 301
...

input:

4
4901 2451
201 301
202 301
203 301
204 301
205 301
206 301
207 301
208 301
209 301
210 301
211 301
212 301
213 301
214 301
215 301
216 301
217 301
218 301
219 301
220 301
221 301
222 301
223 301
224 301
225 301
226 301
227 301
228 301
229 301
230 301
231 301
232 301
233 301
234 301
235 301
236 301
...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
1750

Test #7:

score: 5
Accepted
time: 1ms = 0ms + 1ms
memory: 1872kb,1868kb

input:

5
4878

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
25 1
25 2
25 3
25 4
25 5
25 6
25 7
25 8
25 9
25 10
25 11
25 12
25 13
25 14
25 15
25 16
25 17
25 18
25 19
25 20
25 21
25 22
25 23
25 24
25 26
25 27
25 28
25 29
25 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
25 1
25 2
25 3
25 4
25 5
25 6
25 7
25 8
25 9
25 10
25 11
25 12
25 13
25 14
25 15
25 16
25 17
25 18
25 19
25 20
25 21
25 22
25 23
25 24
25 26
25 27
25 28
25 29
25 30...

output:

6
4901 3773
1 25
101 173
201 220
301 368
401 415
501 563
601 610
701 758
801 805
901 953
1001 1101
1102 1148
1103 1148
1104 1148
1105 1148
1106 1148
1107 1148
1108 1148
1109 1148
1110 1148
1111 1148
1112 1148
1113 1148
1114 1148
1115 1148
1116 1148
1117 1148
1118 1148
1119 1148
1120 1148
1121 1148
1...

input:

6
4901 3773
1 25
101 173
201 220
301 368
401 415
501 563
601 610
701 758
801 805
901 953
1001 1101
1102 1148
1103 1148
1104 1148
1105 1148
1106 1148
1107 1148
1108 1148
1109 1148
1110 1148
1111 1148
1112 1148
1113 1148
1114 1148
1115 1148
1116 1148
1117 1148
1118 1148
1119 1148
1120 1148
1121 1148
1...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
4878

Test #8:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1860kb

input:

5
1223

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
35 1
35 2
35 3
35 4
35 5
35 6
35 7
35 8
35 9
35 10
35 11
35 12
35 13
35 14
35 15
35 16
35 17
35 18
35 19
35 20
35 21
35 22
35 23
35 24
35 25
35 26
35 27
35 28
35 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
35 1
35 2
35 3
35 4
35 5
35 6
35 7
35 8
35 9
35 10
35 11
35 12
35 13
35 14
35 15
35 16
35 17
35 18
35 19
35 20
35 21
35 22
35 23
35 24
35 25
35 26
35 27
35 28
35 29...

output:

6
4901 3480
1 35
101 147
201 259
301 371
401 483
501 595
601 606
701 718
801 830
901 942
1001 1054
1101 1166
1201 1278
1301 1390
1401 1402
1401 1403
1401 1404
1401 1405
1401 1406
1401 1407
1401 1408
1401 1409
1401 1410
1401 1411
1401 1412
1401 1413
1401 1414
1401 1415
1401 1416
1401 1417
1401 1418
1...

input:

6
4901 3480
1 35
101 147
201 259
301 371
401 483
501 595
601 606
701 718
801 830
901 942
1001 1054
1101 1166
1201 1278
1301 1390
1401 1402
1401 1403
1401 1404
1401 1405
1401 1406
1401 1407
1401 1408
1401 1409
1401 1410
1401 1411
1401 1412
1401 1413
1401 1414
1401 1415
1401 1416
1401 1417
1401 1418
1...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
1223

Test #9:

score: 5
Accepted
time: 1ms = 0ms + 1ms
memory: 1864kb,1868kb

input:

5
648

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
54 1
54 2
54 3
54 4
54 5
54 6
54 7
54 8
54 9
54 10
54 11
54 12
54 13
54 14
54 15
54 16
54 17
54 18
54 19
54 20
54 21
54 22
54 23
54 24
54 25
54 26
54 27
54 28
54 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
54 1
54 2
54 3
54 4
54 5
54 6
54 7
54 8
54 9
54 10
54 11
54 12
54 13
54 14
54 15
54 16
54 17
54 18
54 19
54 20
54 21
54 22
54 23
54 24
54 25
54 26
54 27
54 28
54 29...

output:

6
4901 4068
1 54
101 160
201 266
301 372
401 478
501 584
601 690
701 796
801 802
801 803
801 804
801 805
801 806
801 807
801 808
801 809
801 810
801 811
801 812
801 813
801 814
801 815
801 816
801 817
801 818
801 819
801 820
801 821
801 822
801 823
801 824
801 825
801 826
801 827
801 828
801 829
801...

input:

6
4901 4068
1 54
101 160
201 266
301 372
401 478
501 584
601 690
701 796
801 802
801 803
801 804
801 805
801 806
801 807
801 808
801 809
801 810
801 811
801 812
801 813
801 814
801 815
801 816
801 817
801 818
801 819
801 820
801 821
801 822
801 823
801 824
801 825
801 826
801 827
801 828
801 829
801...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
648

Test #10:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1844kb

input:

7
4475

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

output:

8
4901 2451
2 18
5 18
7 18
8 18
10 18
12 18
14 18
17 18
18 19
18 25
18 26
18 27
18 30
18 31
18 32
18 33
18 36
18 38
18 41
18 43
18 44
18 45
18 50
18 52
18 55
18 57
18 58
18 59
18 60
18 61
18 66
18 67
18 70
18 78
18 79
18 82
18 84
18 85
18 86
18 88
18 91
18 93
18 94
18 96
18 97
18 100
105 162
107 162...

input:

8
4901 2451
2 18
5 18
7 18
8 18
10 18
12 18
14 18
17 18
18 19
18 25
18 26
18 27
18 30
18 31
18 32
18 33
18 36
18 38
18 41
18 43
18 44
18 45
18 50
18 52
18 55
18 57
18 58
18 59
18 60
18 61
18 66
18 67
18 70
18 78
18 79
18 82
18 84
18 85
18 86
18 88
18 91
18 93
18 94
18 96
18 97
18 100
105 162
107 162...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
4475

Test #11:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1844kb

input:

7
4240

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
82 1
82 2
82 3
82 4
82 5
82 6
82 7
82 8
82 9
82 10
82 11
82 12
82 13
82 14
82 15
82 16
82 17
82 18
82 19
82 20
82 21
82 22
82 23
82 24
82 25
82 26
82 27
82 28
82 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
82 1
82 2
82 3
82 4
82 5
82 6
82 7
82 8
82 9
82 10
82 11
82 12
82 13
82 14
82 15
82 16
82 17
82 18
82 19
82 20
82 21
82 22
82 23
82 24
82 25
82 26
82 27
82 28
82 29...

output:

8
4901 2451
2 82
5 82
7 82
8 82
10 82
12 82
14 82
17 82
18 82
24 82
25 82
26 82
29 82
30 82
31 82
32 82
35 82
37 82
40 82
42 82
43 82
44 82
49 82
51 82
54 82
56 82
57 82
58 82
59 82
60 82
65 82
66 82
69 82
77 82
78 82
81 82
82 84
82 85
82 86
82 88
82 91
82 93
82 94
82 96
82 97
82 100
105 123
107 123...

input:

8
4901 2451
2 82
5 82
7 82
8 82
10 82
12 82
14 82
17 82
18 82
24 82
25 82
26 82
29 82
30 82
31 82
32 82
35 82
37 82
40 82
42 82
43 82
44 82
49 82
51 82
54 82
56 82
57 82
58 82
59 82
60 82
65 82
66 82
69 82
77 82
78 82
81 82
82 84
82 85
82 86
82 88
82 91
82 93
82 94
82 96
82 97
82 100
105 123
107 123...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
4240

Test #12:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1840kb

input:

7
1291

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
2 1
2 3
2 4
2 5
2 6
2 7
2 8
2 9
2 10
2 11
2 12
2 13
2 14
2 15
2 16
2 17
2 18
2 19
2 20
2 21
2 22
2 23
2 24
2 25
2 26
2 27
2 28
2 29
2 30
2 31
2 32
2 33
2 34
2 35
2 ...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
2 1
2 3
2 4
2 5
2 6
2 7
2 8
2 9
2 10
2 11
2 12
2 13
2 14
2 15
2 16
2 17
2 18
2 19
2 20
2 21
2 22
2 23
2 24
2 25
2 26
2 27
2 28
2 29
2 30
2 31
2 32
2 33
2 34
2 35
2 ...

output:

8
4901 2451
2 3
2 6
2 8
2 9
2 11
2 13
2 15
2 18
2 19
2 25
2 26
2 27
2 30
2 31
2 32
2 33
2 36
2 38
2 41
2 43
2 44
2 45
2 50
2 52
2 55
2 57
2 58
2 59
2 60
2 66
2 67
2 70
2 78
2 79
2 82
2 84
2 85
2 86
2 88
2 89
2 91
2 93
2 94
2 96
2 97
2 100
105 114
107 114
108 114
111 114
114 116
114 120
114 121
114 1...

input:

8
4901 2451
2 3
2 6
2 8
2 9
2 11
2 13
2 15
2 18
2 19
2 25
2 26
2 27
2 30
2 31
2 32
2 33
2 36
2 38
2 41
2 43
2 44
2 45
2 50
2 52
2 55
2 57
2 58
2 59
2 60
2 66
2 67
2 70
2 78
2 79
2 82
2 84
2 85
2 86
2 88
2 89
2 91
2 93
2 94
2 96
2 97
2 100
105 114
107 114
108 114
111 114
114 116
114 120
114 121
114 1...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
1291

Subtask #2:

score: 30
Accepted

Test #13:

score: 30
Accepted
time: 1ms = 0ms + 1ms
memory: 1868kb,1872kb

input:

1
17476204

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
29 1
29 2
29 3
29 4
29 5
29 6
29 7
29 8
29 9
29 10
29 11
29 12
29 13
29 14
29 15
29 16
29 17
29 18
29 19
29 20
29 21
29 22
29 23
29 24
29 25
29 26
29 27
29 28
29 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
29 1
29 2
29 3
29 4
29 5
29 6
29 7
29 8
29 9
29 10
29 11
29 12
29 13
29 14
29 15
29 16
29 17
29 18
29 19
29 20
29 21
29 22
29 23
29 24
29 25
29 26
29 27
29 28
29 30...

output:

2
4901 4204
1 29
5 29
6 29
7 29
9 29
11 29
12 29
13 29
14 29
15 29
17 29
18 29
19 29
20 29
21 29
22 29
23 29
24 29
25 29
27 29
29 30
29 32
29 33
29 34
29 35
29 36
29 37
29 38
29 39
29 40
29 42
29 43
29 44
29 47
29 48
29 49
29 50
29 51
29 52
29 53
29 56
29 57
29 58
29 59
29 60
29 61
29 62
29 63
29 64...

input:

2
4901 4204
1 29
5 29
6 29
7 29
9 29
11 29
12 29
13 29
14 29
15 29
17 29
18 29
19 29
20 29
21 29
22 29
23 29
24 29
25 29
27 29
29 30
29 32
29 33
29 34
29 35
29 36
29 37
29 38
29 39
29 40
29 42
29 43
29 44
29 47
29 48
29 49
29 50
29 51
29 52
29 53
29 56
29 57
29 58
29 59
29 60
29 61
29 62
29 63
29 64...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
17476204

Test #14:

score: 30
Accepted
time: 1ms = 0ms + 1ms
memory: 1872kb,1876kb

input:

1
11926600

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
66 1
66 2
66 3
66 4
66 5
66 6
66 7
66 8
66 9
66 10
66 11
66 12
66 13
66 14
66 15
66 16
66 17
66 18
66 19
66 20
66 21
66 22
66 23
66 24
66 25
66 26
66 27
66 28
66 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
66 1
66 2
66 3
66 4
66 5
66 6
66 7
66 8
66 9
66 10
66 11
66 12
66 13
66 14
66 15
66 16
66 17
66 18
66 19
66 20
66 21
66 22
66 23
66 24
66 25
66 26
66 27
66 28
66 29...

output:

2
4901 4204
1 66
5 66
6 66
7 66
9 66
11 66
12 66
13 66
14 66
15 66
17 66
18 66
19 66
20 66
21 66
22 66
23 66
24 66
25 66
27 66
29 66
31 66
32 66
33 66
34 66
35 66
36 66
37 66
38 66
39 66
41 66
42 66
43 66
46 66
47 66
48 66
49 66
50 66
51 66
52 66
55 66
56 66
57 66
58 66
59 66
60 66
61 66
62 66
63 66...

input:

2
4901 4204
1 66
5 66
6 66
7 66
9 66
11 66
12 66
13 66
14 66
15 66
17 66
18 66
19 66
20 66
21 66
22 66
23 66
24 66
25 66
27 66
29 66
31 66
32 66
33 66
34 66
35 66
36 66
37 66
38 66
39 66
41 66
42 66
43 66
46 66
47 66
48 66
49 66
50 66
51 66
52 66
55 66
56 66
57 66
58 66
59 66
60 66
61 66
62 66
63 66...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
11926600

Test #15:

score: 30
Accepted
time: 1ms = 0ms + 1ms
memory: 1868kb,1868kb

input:

1
16602378

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
76 1
76 2
76 3
76 4
76 5
76 6
76 7
76 8
76 9
76 10
76 11
76 12
76 13
76 14
76 15
76 16
76 17
76 18
76 19
76 20
76 21
76 22
76 23
76 24
76 25
76 26
76 27
76 28
76 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
76 1
76 2
76 3
76 4
76 5
76 6
76 7
76 8
76 9
76 10
76 11
76 12
76 13
76 14
76 15
76 16
76 17
76 18
76 19
76 20
76 21
76 22
76 23
76 24
76 25
76 26
76 27
76 28
76 29...

output:

2
4901 4204
1 76
5 76
6 76
7 76
9 76
11 76
12 76
13 76
14 76
15 76
17 76
18 76
19 76
20 76
21 76
22 76
23 76
24 76
25 76
27 76
29 76
31 76
32 76
33 76
34 76
35 76
36 76
37 76
38 76
39 76
41 76
42 76
43 76
46 76
47 76
48 76
49 76
50 76
51 76
52 76
55 76
56 76
57 76
58 76
59 76
60 76
61 76
62 76
63 76...

input:

2
4901 4204
1 76
5 76
6 76
7 76
9 76
11 76
12 76
13 76
14 76
15 76
17 76
18 76
19 76
20 76
21 76
22 76
23 76
24 76
25 76
27 76
29 76
31 76
32 76
33 76
34 76
35 76
36 76
37 76
38 76
39 76
41 76
42 76
43 76
46 76
47 76
48 76
49 76
50 76
51 76
52 76
55 76
56 76
57 76
58 76
59 76
60 76
61 76
62 76
63 76...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
16602378

Test #16:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1844kb

input:

3
13129243

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
59 1
59 2
59 3
59 4
59 5
59 6
59 7
59 8
59 9
59 10
59 11
59 12
59 13
59 14
59 15
59 16
59 17
59 18
59 19
59 20
59 21
59 22
59 23
59 24
59 25
59 26
59 27
59 28
59 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
59 1
59 2
59 3
59 4
59 5
59 6
59 7
59 8
59 9
59 10
59 11
59 12
59 13
59 14
59 15
59 16
59 17
59 18
59 19
59 20
59 21
59 22
59 23
59 24
59 25
59 26
59 27
59 28
59 29...

output:

4
4901 2451
1 59
2 59
3 59
4 59
5 59
6 59
7 59
8 59
9 59
10 59
11 59
12 59
13 59
14 59
15 59
16 59
17 59
18 59
19 59
20 59
21 59
22 59
23 59
24 59
25 59
26 59
27 59
28 59
29 59
30 59
31 59
32 59
33 59
34 59
35 59
36 59
37 59
38 59
39 59
40 59
41 59
42 59
43 59
44 59
45 59
46 59
47 59
48 59
49 59
50 ...

input:

4
4901 2451
1 59
2 59
3 59
4 59
5 59
6 59
7 59
8 59
9 59
10 59
11 59
12 59
13 59
14 59
15 59
16 59
17 59
18 59
19 59
20 59
21 59
22 59
23 59
24 59
25 59
26 59
27 59
28 59
29 59
30 59
31 59
32 59
33 59
34 59
35 59
36 59
37 59
38 59
39 59
40 59
41 59
42 59
43 59
44 59
45 59
46 59
47 59
48 59
49 59
50 ...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
13129243

Test #17:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1840kb

input:

3
7892141

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
57 1
57 2
57 3
57 4
57 5
57 6
57 7
57 8
57 9
57 10
57 11
57 12
57 13
57 14
57 15
57 16
57 17
57 18
57 19
57 20
57 21
57 22
57 23
57 24
57 25
57 26
57 27
57 28
57 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
57 1
57 2
57 3
57 4
57 5
57 6
57 7
57 8
57 9
57 10
57 11
57 12
57 13
57 14
57 15
57 16
57 17
57 18
57 19
57 20
57 21
57 22
57 23
57 24
57 25
57 26
57 27
57 28
57 29...

output:

4
4901 2451
1601 1611
1602 1611
1603 1611
1604 1611
1605 1611
1606 1611
1607 1611
1608 1611
1609 1611
1610 1611
1611 1612
1611 1613
1611 1614
1611 1615
1611 1616
1611 1617
1611 1618
1611 1619
1611 1620
1611 1621
1611 1622
1611 1623
1611 1624
1611 1625
1611 1626
1611 1627
1611 1628
1611 1629
1611 163...

input:

4
4901 2451
1601 1611
1602 1611
1603 1611
1604 1611
1605 1611
1606 1611
1607 1611
1608 1611
1609 1611
1610 1611
1611 1612
1611 1613
1611 1614
1611 1615
1611 1616
1611 1617
1611 1618
1611 1619
1611 1620
1611 1621
1611 1622
1611 1623
1611 1624
1611 1625
1611 1626
1611 1627
1611 1628
1611 1629
1611 163...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
7892141

Test #18:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1872kb,1844kb

input:

3
21314775

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
73 1
73 2
73 3
73 4
73 5
73 6
73 7
73 8
73 9
73 10
73 11
73 12
73 13
73 14
73 15
73 16
73 17
73 18
73 19
73 20
73 21
73 22
73 23
73 24
73 25
73 26
73 27
73 28
73 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
73 1
73 2
73 3
73 4
73 5
73 6
73 7
73 8
73 9
73 10
73 11
73 12
73 13
73 14
73 15
73 16
73 17
73 18
73 19
73 20
73 21
73 22
73 23
73 24
73 25
73 26
73 27
73 28
73 29...

output:

4
4901 2451
837 901
901 902
901 903
901 904
901 905
901 906
901 907
901 908
901 909
901 910
901 911
901 912
901 913
901 914
901 915
901 916
901 917
901 918
901 919
901 920
901 921
901 922
901 923
901 924
901 925
901 926
901 927
901 928
901 929
901 930
901 931
901 932
901 933
901 934
901 935
901 936
...

input:

4
4901 2451
837 901
901 902
901 903
901 904
901 905
901 906
901 907
901 908
901 909
901 910
901 911
901 912
901 913
901 914
901 915
901 916
901 917
901 918
901 919
901 920
901 921
901 922
901 923
901 924
901 925
901 926
901 927
901 928
901 929
901 930
901 931
901 932
901 933
901 934
901 935
901 936
...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
21314775

Test #19:

score: 30
Accepted
time: 1ms = 0ms + 1ms
memory: 1864kb,1880kb

input:

5
5559540

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
94 1
94 2
94 3
94 4
94 5
94 6
94 7
94 8
94 9
94 10
94 11
94 12
94 13
94 14
94 15
94 16
94 17
94 18
94 19
94 20
94 21
94 22
94 23
94 24
94 25
94 26
94 27
94 28
94 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
94 1
94 2
94 3
94 4
94 5
94 6
94 7
94 8
94 9
94 10
94 11
94 12
94 13
94 14
94 15
94 16
94 17
94 18
94 19
94 20
94 21
94 22
94 23
94 24
94 25
94 26
94 27
94 28
94 29...

output:

6
4901 4851
2 94
3 94
4 94
5 94
6 94
7 94
8 94
9 94
10 94
11 94
12 94
13 94
14 94
15 94
16 94
17 94
18 94
19 94
20 94
21 94
22 94
23 94
24 94
25 94
26 94
27 94
28 94
29 94
30 94
31 94
32 94
33 94
34 94
35 94
36 94
37 94
38 94
39 94
40 94
41 94
42 94
43 94
44 94
45 94
46 94
47 94
48 94
49 94
50 94
51...

input:

6
4901 4851
2 94
3 94
4 94
5 94
6 94
7 94
8 94
9 94
10 94
11 94
12 94
13 94
14 94
15 94
16 94
17 94
18 94
19 94
20 94
21 94
22 94
23 94
24 94
25 94
26 94
27 94
28 94
29 94
30 94
31 94
32 94
33 94
34 94
35 94
36 94
37 94
38 94
39 94
40 94
41 94
42 94
43 94
44 94
45 94
46 94
47 94
48 94
49 94
50 94
51...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
5559540

Test #20:

score: 30
Accepted
time: 1ms = 0ms + 1ms
memory: 1868kb,1880kb

input:

5
9424319

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
12 1
12 2
12 3
12 4
12 5
12 6
12 7
12 8
12 9
12 10
12 11
12 13
12 14
12 15
12 16
12 17
12 18
12 19
12 20
12 21
12 22
12 23
12 24
12 25
12 26
12 27
12 28
12 29
12 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
12 1
12 2
12 3
12 4
12 5
12 6
12 7
12 8
12 9
12 10
12 11
12 13
12 14
12 15
12 16
12 17
12 18
12 19
12 20
12 21
12 22
12 23
12 24
12 25
12 26
12 27
12 28
12 29
12 30...

output:

6
4901 4851
2 12
3 12
4 12
5 12
6 12
7 12
8 12
9 12
10 12
11 12
12 13
12 14
12 15
12 16
12 17
12 18
12 19
12 20
12 21
12 22
12 23
12 24
12 25
12 26
12 27
12 28
12 29
12 30
12 31
12 32
12 33
12 34
12 35
12 36
12 37
12 38
12 39
12 40
12 41
12 42
12 43
12 44
12 45
12 46
12 47
12 48
12 49
12 50
12 51
12...

input:

6
4901 4851
2 12
3 12
4 12
5 12
6 12
7 12
8 12
9 12
10 12
11 12
12 13
12 14
12 15
12 16
12 17
12 18
12 19
12 20
12 21
12 22
12 23
12 24
12 25
12 26
12 27
12 28
12 29
12 30
12 31
12 32
12 33
12 34
12 35
12 36
12 37
12 38
12 39
12 40
12 41
12 42
12 43
12 44
12 45
12 46
12 47
12 48
12 49
12 50
12 51
12...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
9424319

Test #21:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1848kb

input:

5
10955780

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
40 1
40 2
40 3
40 4
40 5
40 6
40 7
40 8
40 9
40 10
40 11
40 12
40 13
40 14
40 15
40 16
40 17
40 18
40 19
40 20
40 21
40 22
40 23
40 24
40 25
40 26
40 27
40 28
40 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
40 1
40 2
40 3
40 4
40 5
40 6
40 7
40 8
40 9
40 10
40 11
40 12
40 13
40 14
40 15
40 16
40 17
40 18
40 19
40 20
40 21
40 22
40 23
40 24
40 25
40 26
40 27
40 28
40 29...

output:

6
4901 2597
1 40
101 148
201 263
301 344
401 451
501 543
601 680
701 720
801 824
901 951
1001 1060
1101 1110
1201 1262
1301 1374
1401 1405
1501 1516
1601 1666
1701 1713
1801 1818
1901 1940
2001 2038
2101 2172
2201 2301
2302 2384
2303 2384
2304 2384
2305 2384
2306 2384
2307 2384
2308 2384
2309 2384
2...

input:

6
4901 2597
1 40
101 148
201 263
301 344
401 451
501 543
601 680
701 720
801 824
901 951
1001 1060
1101 1110
1201 1262
1301 1374
1401 1405
1501 1516
1601 1666
1701 1713
1801 1818
1901 1940
2001 2038
2101 2172
2201 2301
2302 2384
2303 2384
2304 2384
2305 2384
2306 2384
2307 2384
2308 2384
2309 2384
2...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
10955780

Test #22:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1840kb

input:

7
19938721

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

output:

8
4901 2451
2 18
5 18
7 18
8 18
10 18
12 18
14 18
17 18
18 19
18 25
18 26
18 27
18 30
18 31
18 32
18 33
18 36
18 38
18 41
18 43
18 44
18 45
18 50
18 52
18 55
18 57
18 58
18 59
18 60
18 66
18 67
18 70
18 78
18 79
18 82
18 84
18 85
18 86
18 88
18 89
18 91
18 93
18 94
18 96
18 97
18 100
105 112
107 112...

input:

8
4901 2451
2 18
5 18
7 18
8 18
10 18
12 18
14 18
17 18
18 19
18 25
18 26
18 27
18 30
18 31
18 32
18 33
18 36
18 38
18 41
18 43
18 44
18 45
18 50
18 52
18 55
18 57
18 58
18 59
18 60
18 66
18 67
18 70
18 78
18 79
18 82
18 84
18 85
18 86
18 88
18 89
18 91
18 93
18 94
18 96
18 97
18 100
105 112
107 112...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
19938721

Test #23:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1844kb

input:

7
5129508

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
19 1
19 2
19 3
19 4
19 5
19 6
19 7
19 8
19 9
19 10
19 11
19 12
19 13
19 14
19 15
19 16
19 17
19 18
19 20
19 21
19 22
19 23
19 24
19 25
19 26
19 27
19 28
19 29
19 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
19 1
19 2
19 3
19 4
19 5
19 6
19 7
19 8
19 9
19 10
19 11
19 12
19 13
19 14
19 15
19 16
19 17
19 18
19 20
19 21
19 22
19 23
19 24
19 25
19 26
19 27
19 28
19 29
19 30...

output:

8
4901 2451
2 19
5 19
7 19
8 19
10 19
12 19
14 19
17 19
18 19
19 25
19 26
19 27
19 30
19 31
19 32
19 33
19 36
19 38
19 41
19 43
19 44
19 45
19 50
19 52
19 55
19 57
19 58
19 59
19 60
19 61
19 66
19 67
19 70
19 78
19 79
19 82
19 84
19 85
19 86
19 88
19 89
19 91
19 93
19 94
19 96
19 97
19 100
105 184
1...

input:

8
4901 2451
2 19
5 19
7 19
8 19
10 19
12 19
14 19
17 19
18 19
19 25
19 26
19 27
19 30
19 31
19 32
19 33
19 36
19 38
19 41
19 43
19 44
19 45
19 50
19 52
19 55
19 57
19 58
19 59
19 60
19 61
19 66
19 67
19 70
19 78
19 79
19 82
19 84
19 85
19 86
19 88
19 89
19 91
19 93
19 94
19 96
19 97
19 100
105 184
1...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
5129508

Test #24:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1872kb,1844kb

input:

7
15332941

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
17 1
17 2
17 3
17 4
17 5
17 6
17 7
17 8
17 9
17 10
17 11
17 12
17 13
17 14
17 15
17 16
17 18
17 19
17 20
17 21
17 22
17 23
17 24
17 25
17 26
17 27
17 28
17 29
17 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
17 1
17 2
17 3
17 4
17 5
17 6
17 7
17 8
17 9
17 10
17 11
17 12
17 13
17 14
17 15
17 16
17 18
17 19
17 20
17 21
17 22
17 23
17 24
17 25
17 26
17 27
17 28
17 29
17 30...

output:

8
4901 2451
2 17
5 17
7 17
8 17
10 17
12 17
14 17
17 18
17 19
17 25
17 26
17 27
17 30
17 31
17 32
17 33
17 36
17 38
17 41
17 43
17 44
17 45
17 50
17 52
17 55
17 57
17 58
17 59
17 60
17 61
17 66
17 67
17 70
17 78
17 79
17 82
17 84
17 85
17 86
17 88
17 91
17 93
17 94
17 96
17 97
17 100
105 148
107 148...

input:

8
4901 2451
2 17
5 17
7 17
8 17
10 17
12 17
14 17
17 18
17 19
17 25
17 26
17 27
17 30
17 31
17 32
17 33
17 36
17 38
17 41
17 43
17 44
17 45
17 50
17 52
17 55
17 57
17 58
17 59
17 60
17 61
17 66
17 67
17 70
17 78
17 79
17 82
17 84
17 85
17 86
17 88
17 91
17 93
17 94
17 96
17 97
17 100
105 148
107 148...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
15332941

Subtask #3:

score: 65
Accepted

Test #25:

score: 65
Accepted
time: 1ms = 0ms + 1ms
memory: 1868kb,1868kb

input:

1
355365355024496523

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
96 1
96 2
96 3
96 4
96 5
96 6
96 7
96 8
96 9
96 10
96 11
96 12
96 13
96 14
96 15
96 16
96 17
96 18
96 19
96 20
96 21
96 22
96 23
96 24
96 25
96 26
96 27
96 28
96 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
96 1
96 2
96 3
96 4
96 5
96 6
96 7
96 8
96 9
96 10
96 11
96 12
96 13
96 14
96 15
96 16
96 17
96 18
96 19
96 20
96 21
96 22
96 23
96 24
96 25
96 26
96 27
96 28
96 29...

output:

2
4901 4204
1 96
5 96
6 96
7 96
9 96
11 96
12 96
13 96
14 96
15 96
17 96
18 96
19 96
20 96
21 96
22 96
23 96
24 96
25 96
27 96
29 96
31 96
32 96
33 96
34 96
35 96
36 96
37 96
38 96
39 96
41 96
42 96
43 96
46 96
47 96
48 96
49 96
50 96
51 96
52 96
55 96
56 96
57 96
58 96
59 96
60 96
61 96
62 96
63 96...

input:

2
4901 4204
1 96
5 96
6 96
7 96
9 96
11 96
12 96
13 96
14 96
15 96
17 96
18 96
19 96
20 96
21 96
22 96
23 96
24 96
25 96
27 96
29 96
31 96
32 96
33 96
34 96
35 96
36 96
37 96
38 96
39 96
41 96
42 96
43 96
46 96
47 96
48 96
49 96
50 96
51 96
52 96
55 96
56 96
57 96
58 96
59 96
60 96
61 96
62 96
63 96...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
355365355024496523

Test #26:

score: 65
Accepted
time: 1ms = 0ms + 1ms
memory: 1864kb,1872kb

input:

1
727827999106414164

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
14 1
14 2
14 3
14 4
14 5
14 6
14 7
14 8
14 9
14 10
14 11
14 12
14 13
14 15
14 16
14 17
14 18
14 19
14 20
14 21
14 22
14 23
14 24
14 25
14 26
14 27
14 28
14 29
14 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
14 1
14 2
14 3
14 4
14 5
14 6
14 7
14 8
14 9
14 10
14 11
14 12
14 13
14 15
14 16
14 17
14 18
14 19
14 20
14 21
14 22
14 23
14 24
14 25
14 26
14 27
14 28
14 29
14 30...

output:

2
4901 4204
1 14
5 14
6 14
7 14
9 14
11 14
12 14
13 14
14 15
14 16
14 18
14 19
14 20
14 21
14 22
14 23
14 24
14 25
14 26
14 28
14 30
14 32
14 33
14 34
14 35
14 36
14 37
14 38
14 39
14 40
14 42
14 43
14 44
14 47
14 48
14 49
14 50
14 51
14 52
14 53
14 56
14 57
14 58
14 59
14 60
14 61
14 62
14 63
14 64...

input:

2
4901 4204
1 14
5 14
6 14
7 14
9 14
11 14
12 14
13 14
14 15
14 16
14 18
14 19
14 20
14 21
14 22
14 23
14 24
14 25
14 26
14 28
14 30
14 32
14 33
14 34
14 35
14 36
14 37
14 38
14 39
14 40
14 42
14 43
14 44
14 47
14 48
14 49
14 50
14 51
14 52
14 53
14 56
14 57
14 58
14 59
14 60
14 61
14 62
14 63
14 64...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
727827999106414164

Test #27:

score: 65
Accepted
time: 1ms = 0ms + 1ms
memory: 1864kb,1876kb

input:

1
656410143989222955

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
84 1
84 2
84 3
84 4
84 5
84 6
84 7
84 8
84 9
84 10
84 11
84 12
84 13
84 14
84 15
84 16
84 17
84 18
84 19
84 20
84 21
84 22
84 23
84 24
84 25
84 26
84 27
84 28
84 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
84 1
84 2
84 3
84 4
84 5
84 6
84 7
84 8
84 9
84 10
84 11
84 12
84 13
84 14
84 15
84 16
84 17
84 18
84 19
84 20
84 21
84 22
84 23
84 24
84 25
84 26
84 27
84 28
84 29...

output:

2
4901 4204
1 84
5 84
6 84
7 84
9 84
11 84
12 84
13 84
14 84
15 84
17 84
18 84
19 84
20 84
21 84
22 84
23 84
24 84
25 84
27 84
29 84
31 84
32 84
33 84
34 84
35 84
36 84
37 84
38 84
39 84
41 84
42 84
43 84
46 84
47 84
48 84
49 84
50 84
51 84
52 84
55 84
56 84
57 84
58 84
59 84
60 84
61 84
62 84
63 84...

input:

2
4901 4204
1 84
5 84
6 84
7 84
9 84
11 84
12 84
13 84
14 84
15 84
17 84
18 84
19 84
20 84
21 84
22 84
23 84
24 84
25 84
27 84
29 84
31 84
32 84
33 84
34 84
35 84
36 84
37 84
38 84
39 84
41 84
42 84
43 84
46 84
47 84
48 84
49 84
50 84
51 84
52 84
55 84
56 84
57 84
58 84
59 84
60 84
61 84
62 84
63 84...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
656410143989222955

Test #28:

score: 65
Accepted
time: 1ms = 0ms + 1ms
memory: 1868kb,1872kb

input:

1
410366615149657534

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
41 1
41 2
41 3
41 4
41 5
41 6
41 7
41 8
41 9
41 10
41 11
41 12
41 13
41 14
41 15
41 16
41 17
41 18
41 19
41 20
41 21
41 22
41 23
41 24
41 25
41 26
41 27
41 28
41 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
41 1
41 2
41 3
41 4
41 5
41 6
41 7
41 8
41 9
41 10
41 11
41 12
41 13
41 14
41 15
41 16
41 17
41 18
41 19
41 20
41 21
41 22
41 23
41 24
41 25
41 26
41 27
41 28
41 29...

output:

2
4901 4204
1 41
5 41
6 41
7 41
9 41
11 41
12 41
13 41
14 41
15 41
17 41
18 41
19 41
20 41
21 41
22 41
23 41
24 41
25 41
27 41
29 41
31 41
32 41
33 41
34 41
35 41
36 41
37 41
38 41
39 41
41 42
41 43
41 44
41 47
41 48
41 49
41 50
41 51
41 52
41 53
41 56
41 57
41 58
41 59
41 60
41 61
41 62
41 63
41 64...

input:

2
4901 4204
1 41
5 41
6 41
7 41
9 41
11 41
12 41
13 41
14 41
15 41
17 41
18 41
19 41
20 41
21 41
22 41
23 41
24 41
25 41
27 41
29 41
31 41
32 41
33 41
34 41
35 41
36 41
37 41
38 41
39 41
41 42
41 43
41 44
41 47
41 48
41 49
41 50
41 51
41 52
41 53
41 56
41 57
41 58
41 59
41 60
41 61
41 62
41 63
41 64...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
410366615149657534

Test #29:

score: 65
Accepted
time: 1ms = 0ms + 1ms
memory: 1868kb,1876kb

input:

1
298090682780948428

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
75 1
75 2
75 3
75 4
75 5
75 6
75 7
75 8
75 9
75 10
75 11
75 12
75 13
75 14
75 15
75 16
75 17
75 18
75 19
75 20
75 21
75 22
75 23
75 24
75 25
75 26
75 27
75 28
75 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
4901
75 1
75 2
75 3
75 4
75 5
75 6
75 7
75 8
75 9
75 10
75 11
75 12
75 13
75 14
75 15
75 16
75 17
75 18
75 19
75 20
75 21
75 22
75 23
75 24
75 25
75 26
75 27
75 28
75 29...

output:

2
4901 4204
1 75
5 75
6 75
7 75
9 75
11 75
12 75
13 75
14 75
15 75
17 75
18 75
19 75
20 75
21 75
22 75
23 75
24 75
25 75
27 75
29 75
31 75
32 75
33 75
34 75
35 75
36 75
37 75
38 75
39 75
41 75
42 75
43 75
46 75
47 75
48 75
49 75
50 75
51 75
52 75
55 75
56 75
57 75
58 75
59 75
60 75
61 75
62 75
63 75...

input:

2
4901 4204
1 75
5 75
6 75
7 75
9 75
11 75
12 75
13 75
14 75
15 75
17 75
18 75
19 75
20 75
21 75
22 75
23 75
24 75
25 75
27 75
29 75
31 75
32 75
33 75
34 75
35 75
36 75
37 75
38 75
39 75
41 75
42 75
43 75
46 75
47 75
48 75
49 75
50 75
51 75
52 75
55 75
56 75
57 75
58 75
59 75
60 75
61 75
62 75
63 75...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
298090682780948428

Test #30:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1840kb

input:

3
969441916331132577

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
26 1
26 2
26 3
26 4
26 5
26 6
26 7
26 8
26 9
26 10
26 11
26 12
26 13
26 14
26 15
26 16
26 17
26 18
26 19
26 20
26 21
26 22
26 23
26 24
26 25
26 27
26 28
26 29
26 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
26 1
26 2
26 3
26 4
26 5
26 6
26 7
26 8
26 9
26 10
26 11
26 12
26 13
26 14
26 15
26 16
26 17
26 18
26 19
26 20
26 21
26 22
26 23
26 24
26 25
26 27
26 28
26 29
26 30...

output:

4
4901 2451
1601 1683
1602 1683
1603 1683
1604 1683
1605 1683
1606 1683
1607 1683
1608 1683
1609 1683
1610 1683
1611 1683
1612 1683
1613 1683
1614 1683
1615 1683
1616 1683
1617 1683
1618 1683
1619 1683
1620 1683
1621 1683
1622 1683
1623 1683
1624 1683
1625 1683
1626 1683
1627 1683
1628 1683
1629 168...

input:

4
4901 2451
1601 1683
1602 1683
1603 1683
1604 1683
1605 1683
1606 1683
1607 1683
1608 1683
1609 1683
1610 1683
1611 1683
1612 1683
1613 1683
1614 1683
1615 1683
1616 1683
1617 1683
1618 1683
1619 1683
1620 1683
1621 1683
1622 1683
1623 1683
1624 1683
1625 1683
1626 1683
1627 1683
1628 1683
1629 168...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
969441916331132577

Test #31:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1848kb

input:

3
929489812741933634

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
82 1
82 2
82 3
82 4
82 5
82 6
82 7
82 8
82 9
82 10
82 11
82 12
82 13
82 14
82 15
82 16
82 17
82 18
82 19
82 20
82 21
82 22
82 23
82 24
82 25
82 26
82 27
82 28
82 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
82 1
82 2
82 3
82 4
82 5
82 6
82 7
82 8
82 9
82 10
82 11
82 12
82 13
82 14
82 15
82 16
82 17
82 18
82 19
82 20
82 21
82 22
82 23
82 24
82 25
82 26
82 27
82 28
82 29...

output:

4
4901 2451
1427 1501
1501 1502
1501 1503
1501 1504
1501 1505
1501 1506
1501 1507
1501 1508
1501 1509
1501 1510
1501 1511
1501 1512
1501 1513
1501 1514
1501 1515
1501 1516
1501 1517
1501 1518
1501 1519
1501 1520
1501 1521
1501 1522
1501 1523
1501 1524
1501 1525
1501 1526
1501 1527
1501 1528
1501 152...

input:

4
4901 2451
1427 1501
1501 1502
1501 1503
1501 1504
1501 1505
1501 1506
1501 1507
1501 1508
1501 1509
1501 1510
1501 1511
1501 1512
1501 1513
1501 1514
1501 1515
1501 1516
1501 1517
1501 1518
1501 1519
1501 1520
1501 1521
1501 1522
1501 1523
1501 1524
1501 1525
1501 1526
1501 1527
1501 1528
1501 152...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
929489812741933634

Test #32:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1840kb

input:

3
144032041325838295

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
85 1
85 2
85 3
85 4
85 5
85 6
85 7
85 8
85 9
85 10
85 11
85 12
85 13
85 14
85 15
85 16
85 17
85 18
85 19
85 20
85 21
85 22
85 23
85 24
85 25
85 26
85 27
85 28
85 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
85 1
85 2
85 3
85 4
85 5
85 6
85 7
85 8
85 9
85 10
85 11
85 12
85 13
85 14
85 15
85 16
85 17
85 18
85 19
85 20
85 21
85 22
85 23
85 24
85 25
85 26
85 27
85 28
85 29...

output:

4
4901 2451
1601 1667
1602 1667
1603 1667
1604 1667
1605 1667
1606 1667
1607 1667
1608 1667
1609 1667
1610 1667
1611 1667
1612 1667
1613 1667
1614 1667
1615 1667
1616 1667
1617 1667
1618 1667
1619 1667
1620 1667
1621 1667
1622 1667
1623 1667
1624 1667
1625 1667
1626 1667
1627 1667
1628 1667
1629 166...

input:

4
4901 2451
1601 1667
1602 1667
1603 1667
1604 1667
1605 1667
1606 1667
1607 1667
1608 1667
1609 1667
1610 1667
1611 1667
1612 1667
1613 1667
1614 1667
1615 1667
1616 1667
1617 1667
1618 1667
1619 1667
1620 1667
1621 1667
1622 1667
1623 1667
1624 1667
1625 1667
1626 1667
1627 1667
1628 1667
1629 166...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
144032041325838295

Test #33:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1840kb

input:

3
832110946250826180

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
38 1
38 2
38 3
38 4
38 5
38 6
38 7
38 8
38 9
38 10
38 11
38 12
38 13
38 14
38 15
38 16
38 17
38 18
38 19
38 20
38 21
38 22
38 23
38 24
38 25
38 26
38 27
38 28
38 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
38 1
38 2
38 3
38 4
38 5
38 6
38 7
38 8
38 9
38 10
38 11
38 12
38 13
38 14
38 15
38 16
38 17
38 18
38 19
38 20
38 21
38 22
38 23
38 24
38 25
38 26
38 27
38 28
38 29...

output:

4
4901 2451
1 38
2 38
3 38
4 38
5 38
6 38
7 38
8 38
9 38
10 38
11 38
12 38
13 38
14 38
15 38
16 38
17 38
18 38
19 38
20 38
21 38
22 38
23 38
24 38
25 38
26 38
27 38
28 38
29 38
30 38
31 38
32 38
33 38
34 38
35 38
36 38
37 38
38 39
38 40
38 41
38 42
38 43
38 44
38 45
38 46
38 47
38 48
38 49
38 50
38 ...

input:

4
4901 2451
1 38
2 38
3 38
4 38
5 38
6 38
7 38
8 38
9 38
10 38
11 38
12 38
13 38
14 38
15 38
16 38
17 38
18 38
19 38
20 38
21 38
22 38
23 38
24 38
25 38
26 38
27 38
28 38
29 38
30 38
31 38
32 38
33 38
34 38
35 38
36 38
37 38
38 39
38 40
38 41
38 42
38 43
38 44
38 45
38 46
38 47
38 48
38 49
38 50
38 ...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
832110946250826180

Test #34:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1848kb

input:

3
85728715707691821

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
33 1
33 2
33 3
33 4
33 5
33 6
33 7
33 8
33 9
33 10
33 11
33 12
33 13
33 14
33 15
33 16
33 17
33 18
33 19
33 20
33 21
33 22
33 23
33 24
33 25
33 26
33 27
33 28
33 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
4901
33 1
33 2
33 3
33 4
33 5
33 6
33 7
33 8
33 9
33 10
33 11
33 12
33 13
33 14
33 15
33 16
33 17
33 18
33 19
33 20
33 21
33 22
33 23
33 24
33 25
33 26
33 27
33 28
33 29...

output:

4
4901 2451
1 33
2 33
3 33
4 33
5 33
6 33
7 33
8 33
9 33
10 33
11 33
12 33
13 33
14 33
15 33
16 33
17 33
18 33
19 33
20 33
21 33
22 33
23 33
24 33
25 33
26 33
27 33
28 33
29 33
30 33
31 33
32 33
33 34
33 35
33 36
33 37
33 38
33 39
33 40
33 41
33 42
33 43
33 44
33 45
33 46
33 47
33 48
33 49
33 50
33 ...

input:

4
4901 2451
1 33
2 33
3 33
4 33
5 33
6 33
7 33
8 33
9 33
10 33
11 33
12 33
13 33
14 33
15 33
16 33
17 33
18 33
19 33
20 33
21 33
22 33
23 33
24 33
25 33
26 33
27 33
28 33
29 33
30 33
31 33
32 33
33 34
33 35
33 36
33 37
33 38
33 39
33 40
33 41
33 42
33 43
33 44
33 45
33 46
33 47
33 48
33 49
33 50
33 ...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
85728715707691821

Test #35:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1864kb

input:

5
777434612360931036

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
64 1
64 2
64 3
64 4
64 5
64 6
64 7
64 8
64 9
64 10
64 11
64 12
64 13
64 14
64 15
64 16
64 17
64 18
64 19
64 20
64 21
64 22
64 23
64 24
64 25
64 26
64 27
64 28
64 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
64 1
64 2
64 3
64 4
64 5
64 6
64 7
64 8
64 9
64 10
64 11
64 12
64 13
64 14
64 15
64 16
64 17
64 18
64 19
64 20
64 21
64 22
64 23
64 24
64 25
64 26
64 27
64 28
64 29...

output:

6
4901 3773
2 64
3 64
4 64
5 64
6 64
7 64
8 64
9 64
10 64
11 64
12 64
13 64
14 64
15 64
16 64
17 64
18 64
19 64
20 64
21 64
22 64
23 64
24 64
25 64
26 64
27 64
28 64
29 64
30 64
31 64
32 64
33 64
34 64
35 64
36 64
37 64
38 64
39 64
40 64
41 64
42 64
43 64
44 64
45 64
46 64
47 64
48 64
49 64
50 64
51...

input:

6
4901 3773
2 64
3 64
4 64
5 64
6 64
7 64
8 64
9 64
10 64
11 64
12 64
13 64
14 64
15 64
16 64
17 64
18 64
19 64
20 64
21 64
22 64
23 64
24 64
25 64
26 64
27 64
28 64
29 64
30 64
31 64
32 64
33 64
34 64
35 64
36 64
37 64
38 64
39 64
40 64
41 64
42 64
43 64
44 64
45 64
46 64
47 64
48 64
49 64
50 64
51...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
777434612360931036

Test #36:

score: 65
Accepted
time: 1ms = 0ms + 1ms
memory: 1864kb,1876kb

input:

5
705262511549880222

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
7 1
7 2
7 3
7 4
7 5
7 6
7 8
7 9
7 10
7 11
7 12
7 13
7 14
7 15
7 16
7 17
7 18
7 19
7 20
7 21
7 22
7 23
7 24
7 25
7 26
7 27
7 28
7 29
7 30
7 31
7 32
7 33
7 34
7 35
7 ...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
7 1
7 2
7 3
7 4
7 5
7 6
7 8
7 9
7 10
7 11
7 12
7 13
7 14
7 15
7 16
7 17
7 18
7 19
7 20
7 21
7 22
7 23
7 24
7 25
7 26
7 27
7 28
7 29
7 30
7 31
7 32
7 33
7 34
7 35
7 ...

output:

6
4901 4851
2 7
3 7
4 7
5 7
6 7
7 8
7 9
7 10
7 11
7 12
7 13
7 14
7 15
7 16
7 17
7 18
7 19
7 20
7 21
7 22
7 23
7 24
7 25
7 26
7 27
7 28
7 29
7 30
7 31
7 32
7 33
7 34
7 35
7 36
7 37
7 38
7 39
7 40
7 41
7 42
7 43
7 44
7 45
7 46
7 47
7 48
7 49
7 50
7 51
7 52
7 53
7 54
7 55
7 56
7 57
7 58
7 59
7 60
7 61
...

input:

6
4901 4851
2 7
3 7
4 7
5 7
6 7
7 8
7 9
7 10
7 11
7 12
7 13
7 14
7 15
7 16
7 17
7 18
7 19
7 20
7 21
7 22
7 23
7 24
7 25
7 26
7 27
7 28
7 29
7 30
7 31
7 32
7 33
7 34
7 35
7 36
7 37
7 38
7 39
7 40
7 41
7 42
7 43
7 44
7 45
7 46
7 47
7 48
7 49
7 50
7 51
7 52
7 53
7 54
7 55
7 56
7 57
7 58
7 59
7 60
7 61
...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
705262511549880222

Test #37:

score: 65
Accepted
time: 1ms = 0ms + 1ms
memory: 1872kb,1880kb

input:

5
510318082834167951

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
86 1
86 2
86 3
86 4
86 5
86 6
86 7
86 8
86 9
86 10
86 11
86 12
86 13
86 14
86 15
86 16
86 17
86 18
86 19
86 20
86 21
86 22
86 23
86 24
86 25
86 26
86 27
86 28
86 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
86 1
86 2
86 3
86 4
86 5
86 6
86 7
86 8
86 9
86 10
86 11
86 12
86 13
86 14
86 15
86 16
86 17
86 18
86 19
86 20
86 21
86 22
86 23
86 24
86 25
86 26
86 27
86 28
86 29...

output:

6
4901 4851
2 86
3 86
4 86
5 86
6 86
7 86
8 86
9 86
10 86
11 86
12 86
13 86
14 86
15 86
16 86
17 86
18 86
19 86
20 86
21 86
22 86
23 86
24 86
25 86
26 86
27 86
28 86
29 86
30 86
31 86
32 86
33 86
34 86
35 86
36 86
37 86
38 86
39 86
40 86
41 86
42 86
43 86
44 86
45 86
46 86
47 86
48 86
49 86
50 86
51...

input:

6
4901 4851
2 86
3 86
4 86
5 86
6 86
7 86
8 86
9 86
10 86
11 86
12 86
13 86
14 86
15 86
16 86
17 86
18 86
19 86
20 86
21 86
22 86
23 86
24 86
25 86
26 86
27 86
28 86
29 86
30 86
31 86
32 86
33 86
34 86
35 86
36 86
37 86
38 86
39 86
40 86
41 86
42 86
43 86
44 86
45 86
46 86
47 86
48 86
49 86
50 86
51...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
510318082834167951

Test #38:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1864kb,1856kb

input:

5
914858813253258744

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
14 1
14 2
14 3
14 4
14 5
14 6
14 7
14 8
14 9
14 10
14 11
14 12
14 13
14 15
14 16
14 17
14 18
14 19
14 20
14 21
14 22
14 23
14 24
14 25
14 26
14 27
14 28
14 29
14 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
14 1
14 2
14 3
14 4
14 5
14 6
14 7
14 8
14 9
14 10
14 11
14 12
14 13
14 15
14 16
14 17
14 18
14 19
14 20
14 21
14 22
14 23
14 24
14 25
14 26
14 27
14 28
14 29
14 30...

output:

6
4901 3381
2 14
3 14
4 14
5 14
6 14
7 14
8 14
9 14
10 14
11 14
12 14
13 14
14 15
14 16
14 17
14 18
14 19
14 20
14 21
14 22
14 23
14 24
14 25
14 26
14 27
14 28
14 29
14 30
14 31
14 32
14 33
14 34
14 35
14 36
14 37
14 38
14 39
14 40
14 41
14 42
14 43
14 44
14 45
14 46
14 47
14 48
14 49
14 50
14 51
14...

input:

6
4901 3381
2 14
3 14
4 14
5 14
6 14
7 14
8 14
9 14
10 14
11 14
12 14
13 14
14 15
14 16
14 17
14 18
14 19
14 20
14 21
14 22
14 23
14 24
14 25
14 26
14 27
14 28
14 29
14 30
14 31
14 32
14 33
14 34
14 35
14 36
14 37
14 38
14 39
14 40
14 41
14 42
14 43
14 44
14 45
14 46
14 47
14 48
14 49
14 50
14 51
14...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
914858813253258744

Test #39:

score: 65
Accepted
time: 1ms = 0ms + 1ms
memory: 1872kb,1876kb

input:

5
659635316746638238

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

output:

6
4901 4851
2 18
3 18
4 18
5 18
6 18
7 18
8 18
9 18
10 18
11 18
12 18
13 18
14 18
15 18
16 18
17 18
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30
18 31
18 32
18 33
18 34
18 35
18 36
18 37
18 38
18 39
18 40
18 41
18 42
18 43
18 44
18 45
18 46
18 47
18 48
18 49
18 50
18 51
18...

input:

6
4901 4851
2 18
3 18
4 18
5 18
6 18
7 18
8 18
9 18
10 18
11 18
12 18
13 18
14 18
15 18
16 18
17 18
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30
18 31
18 32
18 33
18 34
18 35
18 36
18 37
18 38
18 39
18 40
18 41
18 42
18 43
18 44
18 45
18 46
18 47
18 48
18 49
18 50
18 51
18...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
659635316746638238

Test #40:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1844kb

input:

7
858490260563149759

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
18 1
18 2
18 3
18 4
18 5
18 6
18 7
18 8
18 9
18 10
18 11
18 12
18 13
18 14
18 15
18 16
18 17
18 19
18 20
18 21
18 22
18 23
18 24
18 25
18 26
18 27
18 28
18 29
18 30...

output:

8
4901 2451
2 18
5 18
7 18
8 18
10 18
12 18
14 18
17 18
18 19
18 25
18 26
18 27
18 30
18 31
18 32
18 33
18 36
18 38
18 41
18 43
18 44
18 45
18 48
18 50
18 52
18 55
18 57
18 58
18 59
18 60
18 61
18 66
18 67
18 70
18 78
18 79
18 82
18 84
18 85
18 86
18 88
18 89
18 91
18 93
18 94
18 96
18 97
18 100
202...

input:

8
4901 2451
2 18
5 18
7 18
8 18
10 18
12 18
14 18
17 18
18 19
18 25
18 26
18 27
18 30
18 31
18 32
18 33
18 36
18 38
18 41
18 43
18 44
18 45
18 48
18 50
18 52
18 55
18 57
18 58
18 59
18 60
18 61
18 66
18 67
18 70
18 78
18 79
18 82
18 84
18 85
18 86
18 88
18 89
18 91
18 93
18 94
18 96
18 97
18 100
202...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
858490260563149759

Test #41:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1840kb

input:

7
860058643727731209

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
63 1
63 2
63 3
63 4
63 5
63 6
63 7
63 8
63 9
63 10
63 11
63 12
63 13
63 14
63 15
63 16
63 17
63 18
63 19
63 20
63 21
63 22
63 23
63 24
63 25
63 26
63 27
63 28
63 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
63 1
63 2
63 3
63 4
63 5
63 6
63 7
63 8
63 9
63 10
63 11
63 12
63 13
63 14
63 15
63 16
63 17
63 18
63 19
63 20
63 21
63 22
63 23
63 24
63 25
63 26
63 27
63 28
63 29...

output:

8
4901 2451
2 63
5 63
7 63
8 63
10 63
12 63
14 63
17 63
18 63
24 63
25 63
26 63
29 63
30 63
31 63
32 63
35 63
37 63
38 63
40 63
42 63
43 63
44 63
47 63
49 63
51 63
54 63
56 63
57 63
58 63
59 63
60 63
63 64
63 66
63 67
63 70
63 78
63 79
63 82
63 84
63 85
63 86
63 88
63 89
63 91
63 93
63 94
63 96
63 9...

input:

8
4901 2451
2 63
5 63
7 63
8 63
10 63
12 63
14 63
17 63
18 63
24 63
25 63
26 63
29 63
30 63
31 63
32 63
35 63
37 63
38 63
40 63
42 63
43 63
44 63
47 63
49 63
51 63
54 63
56 63
57 63
58 63
59 63
60 63
63 64
63 66
63 67
63 70
63 78
63 79
63 82
63 84
63 85
63 86
63 88
63 89
63 91
63 93
63 94
63 96
63 9...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
860058643727731209

Test #42:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1844kb

input:

7
718861404514377808

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
38 1
38 2
38 3
38 4
38 5
38 6
38 7
38 8
38 9
38 10
38 11
38 12
38 13
38 14
38 15
38 16
38 17
38 18
38 19
38 20
38 21
38 22
38 23
38 24
38 25
38 26
38 27
38 28
38 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
38 1
38 2
38 3
38 4
38 5
38 6
38 7
38 8
38 9
38 10
38 11
38 12
38 13
38 14
38 15
38 16
38 17
38 18
38 19
38 20
38 21
38 22
38 23
38 24
38 25
38 26
38 27
38 28
38 29...

output:

8
4901 2451
2 38
5 38
7 38
8 38
10 38
12 38
14 38
17 38
18 38
24 38
25 38
26 38
29 38
30 38
31 38
32 38
35 38
37 38
38 41
38 43
38 44
38 45
38 50
38 52
38 55
38 57
38 58
38 59
38 60
38 61
38 66
38 67
38 70
38 78
38 79
38 82
38 84
38 85
38 86
38 88
38 91
38 93
38 94
38 96
38 97
38 100
105 114
107 114...

input:

8
4901 2451
2 38
5 38
7 38
8 38
10 38
12 38
14 38
17 38
18 38
24 38
25 38
26 38
29 38
30 38
31 38
32 38
35 38
37 38
38 41
38 43
38 44
38 45
38 50
38 52
38 55
38 57
38 58
38 59
38 60
38 61
38 66
38 67
38 70
38 78
38 79
38 82
38 84
38 85
38 86
38 88
38 91
38 93
38 94
38 96
38 97
38 100
105 114
107 114...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
718861404514377808

Test #43:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1840kb

input:

7
659192688464047828

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
69 1
69 2
69 3
69 4
69 5
69 6
69 7
69 8
69 9
69 10
69 11
69 12
69 13
69 14
69 15
69 16
69 17
69 18
69 19
69 20
69 21
69 22
69 23
69 24
69 25
69 26
69 27
69 28
69 29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
69 1
69 2
69 3
69 4
69 5
69 6
69 7
69 8
69 9
69 10
69 11
69 12
69 13
69 14
69 15
69 16
69 17
69 18
69 19
69 20
69 21
69 22
69 23
69 24
69 25
69 26
69 27
69 28
69 29...

output:

8
4901 2451
2 69
5 69
7 69
8 69
10 69
12 69
14 69
17 69
18 69
24 69
25 69
26 69
29 69
30 69
31 69
32 69
35 69
37 69
40 69
42 69
43 69
44 69
49 69
51 69
54 69
56 69
57 69
58 69
59 69
65 69
66 69
69 70
69 78
69 79
69 82
69 84
69 85
69 86
69 88
69 89
69 91
69 93
69 94
69 96
69 97
69 100
105 128
107 128...

input:

8
4901 2451
2 69
5 69
7 69
8 69
10 69
12 69
14 69
17 69
18 69
24 69
25 69
26 69
29 69
30 69
31 69
32 69
35 69
37 69
40 69
42 69
43 69
44 69
49 69
51 69
54 69
56 69
57 69
58 69
59 69
65 69
66 69
69 70
69 78
69 79
69 82
69 84
69 85
69 86
69 88
69 89
69 91
69 93
69 94
69 96
69 97
69 100
105 128
107 128...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
659192688464047828

Test #44:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1868kb,1848kb

input:

7
685730986714800201

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
13 1
13 2
13 3
13 4
13 5
13 6
13 7
13 8
13 9
13 10
13 11
13 12
13 14
13 15
13 16
13 17
13 18
13 19
13 20
13 21
13 22
13 23
13 24
13 25
13 26
13 27
13 28
13 29
13 30...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
4901
13 1
13 2
13 3
13 4
13 5
13 6
13 7
13 8
13 9
13 10
13 11
13 12
13 14
13 15
13 16
13 17
13 18
13 19
13 20
13 21
13 22
13 23
13 24
13 25
13 26
13 27
13 28
13 29
13 30...

output:

8
4901 2451
2 13
5 13
7 13
8 13
10 13
12 13
13 15
13 18
13 19
13 25
13 26
13 27
13 30
13 31
13 32
13 33
13 36
13 38
13 39
13 41
13 43
13 44
13 45
13 48
13 50
13 52
13 55
13 57
13 58
13 59
13 60
13 61
13 66
13 67
13 70
13 78
13 79
13 82
13 84
13 85
13 86
13 88
13 89
13 91
13 93
13 94
13 96
13 97
13 1...

input:

8
4901 2451
2 13
5 13
7 13
8 13
10 13
12 13
13 15
13 18
13 19
13 25
13 26
13 27
13 30
13 31
13 32
13 33
13 36
13 38
13 39
13 41
13 43
13 44
13 45
13 48
13 50
13 52
13 55
13 57
13 58
13 59
13 60
13 61
13 66
13 67
13 70
13 78
13 79
13 82
13 84
13 85
13 86
13 88
13 89
13 91
13 93
13 94
13 96
13 97
13 1...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
685730986714800201