QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#422124#8726. Magic Show5sb100 ✓0ms1776kbC++23291b2024-05-26 20:02:222024-05-26 20:02:22

Judging History

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

  • [2024-05-26 20:02:22]
  • 评测
  • 测评结果:100
  • 用时:0ms
  • 内存:1776kb
  • [2024-05-26 20:02:22]
  • 提交

Alice

#import"Alice.h"
using a=std::vector<std::pair<int,int>>;a Alice(){a b;for(auto c=99ll,d=setN(c);--c;b.push_back({d%c+1,c+1}));return b;}

Bob

#import"Bob.h"
long long Bob(std::vector<std::pair<int,int>>a){auto b=0z,c=1z;for(auto[d,e]:a){for(d--,e--;b%e!=d;b+=c);for(auto f=c;c%e;c+=f);}return b;}

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: 1764kb,1772kb

input:

1
4005

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
86 99
29 98
70 97
16 96
58 95
7 94
50 93
2 92
46 91
1 90
46 89
4 88
50 87
11 86
58 85
22 84
70 83
37 82
6 81
56 80
28 79
2 78
54 77
31 76
10 75
64 74
46 73
30 72
16 7...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
86 99
29 98
70 97
16 96
58 95
7 94
50 93
2 92
46 91
1 90
46 89
4 88
50 87
11 86
58 85
22 84
70 83
37 82
6 81
56 80
28 79
2 78
54 77
31 76
10 75
64 74
46 73
30 72
16 7...

output:

2
99 84
1 2
1 4
1 10
1 16
1 46
1 90
2 3
2 5
2 8
2 12
2 14
2 15
2 23
2 27
2 29
2 45
2 53
2 78
2 92
4 24
4 30
4 59
4 70
4 88
6 11
6 17
6 21
6 26
6 33
6 81
7 32
7 44
7 94
10 13
10 19
10 28
10 37
10 38
10 55
10 75
11 18
11 48
11 86
13 34
16 20
16 31
16 36
16 39
16 43
16 71
16 96
22 25
22 49
28 35
28 40
...

input:

2
99 84
1 2
1 4
1 10
1 16
1 46
1 90
2 3
2 5
2 8
2 12
2 14
2 15
2 23
2 27
2 29
2 45
2 53
2 78
2 92
4 24
4 30
4 59
4 70
4 88
6 11
6 17
6 21
6 26
6 33
6 81
7 32
7 44
7 94
10 13
10 19
10 28
10 37
10 38
10 55
10 75
11 18
11 48
11 86
13 34
16 20
16 31
16 36
16 39
16 43
16 71
16 96
22 25
22 49
28 35
28 40
...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
4005

Test #2:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1768kb

input:

1
459

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
68 99
72 98
76 97
80 96
84 95
88 94
92 93
5 92
10 91
15 90
20 89
25 88
30 87
35 86
40 85
45 84
50 83
55 82
60 81
65 80
70 79
75 78
4 77
10 76
16 75
22 74
28 73
34 72
...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
68 99
72 98
76 97
80 96
84 95
88 94
92 93
5 92
10 91
15 90
20 89
25 88
30 87
35 86
40 85
45 84
50 83
55 82
60 81
65 80
70 79
75 78
4 77
10 76
16 75
22 74
28 73
34 72
...

output:

2
99 84
1 2
1 4
1 10
1 18
1 28
1 52
2 3
4 5
4 13
4 20
4 25
4 39
4 77
5 8
5 14
5 36
5 66
5 92
9 12
9 42
10 11
10 16
10 19
10 26
10 31
10 46
10 76
12 15
12 17
12 29
12 33
12 57
12 65
15 90
16 38
16 75
18 27
18 35
19 50
19 64
20 21
20 23
20 45
20 56
20 89
23 24
25 30
25 88
26 32
26 63
28 37
28 49
28 55...

input:

2
99 84
1 2
1 4
1 10
1 18
1 28
1 52
2 3
4 5
4 13
4 20
4 25
4 39
4 77
5 8
5 14
5 36
5 66
5 92
9 12
9 42
10 11
10 16
10 19
10 26
10 31
10 46
10 76
12 15
12 17
12 29
12 33
12 57
12 65
15 90
16 38
16 75
18 27
18 35
19 50
19 64
20 21
20 23
20 45
20 56
20 89
23 24
25 30
25 88
26 32
26 63
28 37
28 49
28 55...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
459

Test #3:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1768kb

input:

1
2495

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
46 99
71 98
96 97
26 96
52 95
78 94
12 93
39 92
66 91
4 90
32 89
60 88
2 87
31 86
60 85
6 84
36 83
66 82
16 81
47 80
78 79
32 78
64 77
21 76
54 75
14 74
48 73
11 72
4...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
46 99
71 98
96 97
26 96
52 95
78 94
12 93
39 92
66 91
4 90
32 89
60 88
2 87
31 86
60 85
6 84
36 83
66 82
16 81
47 80
78 79
32 78
64 77
21 76
54 75
14 74
48 73
11 72
4...

output:

2
99 84
1 2
2 3
2 30
2 44
2 59
2 87
3 4
3 10
4 5
4 8
4 15
4 29
4 90
5 48
5 54
6 11
6 16
6 31
7 20
10 12
10 23
11 36
12 13
12 19
12 24
12 28
12 37
12 55
12 70
12 93
13 14
14 18
14 35
16 17
16 21
16 32
16 63
16 81
17 38
17 68
18 43
18 60
21 26
21 34
21 46
21 56
21 76
24 25
26 27
26 39
26 66
26 96
31 8...

input:

2
99 84
1 2
2 3
2 30
2 44
2 59
2 87
3 4
3 10
4 5
4 8
4 15
4 29
4 90
5 48
5 54
6 11
6 16
6 31
7 20
10 12
10 23
11 36
12 13
12 19
12 24
12 28
12 37
12 55
12 70
12 93
13 14
14 18
14 35
16 17
16 21
16 32
16 63
16 81
17 38
17 68
18 43
18 60
21 26
21 34
21 46
21 56
21 76
24 25
26 27
26 39
26 66
26 96
31 8...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
2495

Test #4:

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

input:

3
1560

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
91 99
9 98
25 97
41 96
57 95
73 94
89 93
14 92
31 91
48 90
65 89
82 88
13 87
31 86
49 85
67 84
3 83
22 82
41 81
60 80
1 79
21 78
41 77
61 76
7 75
28 74
49 73
70 72
21...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
91 99
9 98
25 97
41 96
57 95
73 94
89 93
14 92
31 91
48 90
65 89
82 88
13 87
31 86
49 85
67 84
3 83
22 82
41 81
60 80
1 79
21 78
41 77
61 76
7 75
28 74
49 73
70 72
21...

output:

4
99 50
1 2
1 3
1 4
1 5
1 6
1 7
1 9
1 11
1 13
1 14
1 16
1 21
1 25
1 27
1 31
1 40
1 41
1 53
1 61
1 66
1 79
9 17
9 98
14 18
14 92
20 24
20 68
24 30
24 54
27 60
28 74
36 62
41 81
41 96
42 50
43 47
43 67
48 90
53 59
57 95
60 80
61 76
65 69
65 89
67 84
70 72
73 94
82 88
89 93
91 99

input:

4
99 50
1 2
1 3
1 4
1 5
1 6
1 7
1 9
1 11
1 13
1 14
1 16
1 21
1 25
1 27
1 31
1 40
1 41
1 53
1 61
1 66
1 79
9 17
9 98
14 18
14 92
20 24
20 68
24 30
24 54
27 60
28 74
36 62
41 81
41 96
42 50
43 47
43 67
48 90
53 59
57 95
60 80
61 76
65 69
65 89
67 84
70 72
73 94
82 88
89 93
91 99

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
1560

Test #5:

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

input:

3
3594

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
67 99
6 98
43 97
80 96
23 95
61 94
7 93
46 92
85 91
35 90
75 89
28 88
69 87
25 86
67 85
26 84
69 83
31 82
75 81
40 80
7 79
53 78
23 77
70 76
43 75
18 74
67 73
45 72
2...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
67 99
6 98
43 97
80 96
23 95
61 94
7 93
46 92
85 91
35 90
75 89
28 88
69 87
25 86
67 85
26 84
69 83
31 82
75 81
40 80
7 79
53 78
23 77
70 76
43 75
18 74
67 73
45 72
2...

output:

4
99 50
1 7
5 6
6 38
6 98
7 13
7 14
7 24
7 27
7 40
7 47
7 53
7 70
7 79
7 93
8 18
9 12
10 16
13 19
15 21
18 50
18 74
26 44
26 84
30 32
35 41
35 90
40 46
40 80
43 49
43 75
44 54
44 68
45 51
45 72
46 92
53 78
55 60
55 61
57 59
57 62
59 69
61 63
61 94
69 83
69 87
70 76
75 81
75 89
80 96
85 91

input:

4
99 50
1 7
5 6
6 38
6 98
7 13
7 14
7 24
7 27
7 40
7 47
7 53
7 70
7 79
7 93
8 18
9 12
10 16
13 19
15 21
18 50
18 74
26 44
26 84
30 32
35 41
35 90
40 46
40 80
43 49
43 75
44 54
44 68
45 51
45 72
46 92
53 78
55 60
55 61
57 59
57 62
59 69
61 63
61 94
69 83
69 87
70 76
75 81
75 89
80 96
85 91

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
3594

Test #6:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1764kb

input:

3
1750

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
85 99
5 98
23 97
41 96
59 95
77 94
3 93
22 92
41 91
60 90
79 89
11 88
31 87
51 86
71 85
8 84
29 83
50 82
71 81
13 80
35 79
57 78
3 77
26 76
49 75
72 74
23 73
47 72
1 ...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
85 99
5 98
23 97
41 96
59 95
77 94
3 93
22 92
41 91
60 90
79 89
11 88
31 87
51 86
71 85
8 84
29 83
50 82
71 81
13 80
35 79
57 78
3 77
26 76
49 75
72 74
23 73
47 72
1 ...

output:

4
99 50
1 2
1 3
1 6
1 8
1 11
1 15
1 26
1 36
1 51
1 71
7 9
7 17
8 22
8 84
9 14
9 27
9 68
12 48
13 80
17 18
17 52
22 92
26 70
26 76
29 42
29 43
29 83
31 44
31 87
36 50
40 60
41 91
43 62
46 56
47 72
49 75
50 64
50 82
51 69
51 86
57 78
59 95
60 90
61 66
71 81
71 85
72 74
77 94
79 89
85 99

input:

4
99 50
1 2
1 3
1 6
1 8
1 11
1 15
1 26
1 36
1 51
1 71
7 9
7 17
8 22
8 84
9 14
9 27
9 68
12 48
13 80
17 18
17 52
22 92
26 70
26 76
29 42
29 43
29 83
31 44
31 87
36 50
40 60
41 91
43 62
46 56
47 72
49 75
50 64
50 82
51 69
51 86
57 78
59 95
60 90
61 66
71 81
71 85
72 74
77 94
79 89
85 99

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
1750

Test #7:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1772kb

input:

5
4878

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
77 99
29 98
79 97
34 96
85 95
43 94
3 93
56 92
19 91
73 90
39 89
7 88
63 87
34 86
7 85
65 84
41 83
19 82
79 81
60 80
43 79
28 78
15 77
4 76
69 75
61 74
55 73
51 72
49...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
77 99
29 98
79 97
34 96
85 95
43 94
3 93
56 92
19 91
73 90
39 89
7 88
63 87
34 86
7 85
65 84
41 83
19 82
79 81
60 80
43 79
28 78
15 77
4 76
69 75
61 74
55 73
51 72
49...

output:

6
99 62
1 2
3 5
3 24
3 47
3 54
3 93
4 6
4 14
4 16
4 26
4 40
4 66
4 76
7 8
7 9
7 13
7 15
7 22
7 25
7 29
7 30
7 43
7 57
7 59
7 85
7 88
12 32
17 18
17 23
17 27
17 35
19 21
19 28
19 31
19 37
19 46
19 55
19 61
19 82
19 91
20 44
34 52
34 58
34 86
34 96
38 48
39 41
39 45
39 56
39 89
49 70
49 71
51 69
51 72...

input:

6
99 62
1 2
3 5
3 24
3 47
3 54
3 93
4 6
4 14
4 16
4 26
4 40
4 66
4 76
7 8
7 9
7 13
7 15
7 22
7 25
7 29
7 30
7 43
7 57
7 59
7 85
7 88
12 32
17 18
17 23
17 27
17 35
19 21
19 28
19 31
19 37
19 46
19 55
19 61
19 82
19 91
20 44
34 52
34 58
34 86
34 96
38 48
39 41
39 45
39 56
39 89
49 70
49 71
51 69
51 72...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
4878

Test #8:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1764kb

input:

5
1223

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
48 99
60 98
72 97
84 96
2 95
15 94
28 93
41 92
54 91
67 90
80 89
6 88
20 87
34 86
48 85
62 84
76 83
9 82
24 81
39 80
54 79
69 78
8 77
24 76
40 75
56 74
72 73
17 72
34...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
48 99
60 98
72 97
84 96
2 95
15 94
28 93
41 92
54 91
67 90
80 89
6 88
20 87
34 86
48 85
62 84
76 83
9 82
24 81
39 80
54 79
69 78
8 77
24 76
40 75
56 74
72 73
17 72
34...

output:

6
99 51
2 3
2 14
2 27
2 48
2 95
4 5
4 6
4 11
4 21
4 62
8 9
8 17
8 20
8 33
8 39
8 65
8 77
12 13
15 32
15 40
15 94
18 19
18 68
24 25
24 26
24 31
24 41
24 49
24 51
24 61
24 76
24 81
28 47
28 53
28 93
34 35
34 36
34 71
34 86
44 60
46 63
54 66
54 79
54 91
56 74
67 90
69 78
72 73
72 97
80 89
84 96

input:

6
99 51
2 3
2 14
2 27
2 48
2 95
4 5
4 6
4 11
4 21
4 62
8 9
8 17
8 20
8 33
8 39
8 65
8 77
12 13
15 32
15 40
15 94
18 19
18 68
24 25
24 26
24 31
24 41
24 49
24 51
24 61
24 76
24 81
28 47
28 53
28 93
34 35
34 36
34 71
34 86
44 60
46 63
54 66
54 79
54 91
56 74
67 90
69 78
72 73
72 97
80 89
84 96

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
1223

Test #9:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1764kb

input:

5
648

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
61 99
67 98
73 97
79 96
85 95
91 94
5 93
12 92
19 91
26 90
33 89
40 88
47 87
54 86
61 85
68 84
75 83
1 82
9 81
17 80
25 79
33 78
41 77
49 76
57 75
65 74
1 73
10 72
19...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
61 99
67 98
73 97
79 96
85 95
91 94
5 93
12 92
19 91
26 90
33 89
40 88
47 87
54 86
61 85
68 84
75 83
1 82
9 81
17 80
25 79
33 78
41 77
49 76
57 75
65 74
1 73
10 72
19...

output:

6
99 52
1 2
3 18
3 20
3 35
3 39
4 6
4 16
4 44
5 8
5 15
5 24
5 29
5 47
5 93
9 11
9 17
9 21
9 33
9 41
9 65
9 81
10 72
12 14
12 50
12 92
13 54
19 22
19 31
19 36
19 43
19 46
19 64
19 71
19 91
25 27
25 40
25 49
25 53
25 79
26 90
28 70
34 42
37 52
37 69
38 48
55 67
57 75
59 60
61 85
61 99
68 84
73 97

input:

6
99 52
1 2
3 18
3 20
3 35
3 39
4 6
4 16
4 44
5 8
5 15
5 24
5 29
5 47
5 93
9 11
9 17
9 21
9 33
9 41
9 65
9 81
10 72
12 14
12 50
12 92
13 54
19 22
19 31
19 36
19 43
19 46
19 64
19 71
19 91
25 27
25 40
25 49
25 53
25 79
26 90
28 70
34 42
37 52
37 69
38 48
55 67
57 75
59 60
61 85
61 99
68 84
73 97

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
648

Test #10:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1768kb

input:

7
4475

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
66 99
14 98
60 97
11 96
58 95
12 94
60 93
17 92
66 91
26 90
76 89
39 88
4 87
56 86
24 85
77 84
48 83
21 82
76 81
52 80
30 79
10 78
68 77
51 76
36 75
23 74
12 73
3 72
...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
66 99
14 98
60 97
11 96
58 95
12 94
60 93
17 92
66 91
26 90
76 89
39 88
4 87
56 86
24 85
77 84
48 83
21 82
76 81
52 80
30 79
10 78
68 77
51 76
36 75
23 74
12 73
3 72
...

output:

8
99 50
5 18
7 42
11 20
11 96
12 13
12 19
12 25
12 37
12 49
12 63
12 73
12 94
14 47
14 98
17 50
17 92
22 35
23 62
23 74
24 29
24 43
24 85
26 90
28 33
30 40
30 79
32 45
36 38
36 41
36 61
36 75
39 88
48 55
48 83
52 57
52 80
54 67
56 69
56 86
58 95
60 65
60 70
60 93
60 97
66 71
66 91
66 99
76 81
76 89
...

input:

8
99 50
5 18
7 42
11 20
11 96
12 13
12 19
12 25
12 37
12 49
12 63
12 73
12 94
14 47
14 98
17 50
17 92
22 35
23 62
23 74
24 29
24 43
24 85
26 90
28 33
30 40
30 79
32 45
36 38
36 41
36 61
36 75
39 88
48 55
48 83
52 57
52 80
54 67
56 69
56 86
58 95
60 65
60 70
60 93
60 97
66 71
66 91
66 99
76 81
76 89
...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
4475

Test #11:

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

input:

7
4240

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
27 99
70 98
17 97
61 96
11 95
56 94
9 93
55 92
11 91
58 90
17 89
65 88
27 87
76 86
41 85
8 84
59 83
29 82
1 81
54 80
29 79
6 78
61 77
41 76
23 75
7 74
65 73
52 72
41 ...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
27 99
70 98
17 97
61 96
11 95
56 94
9 93
55 92
11 91
58 90
17 89
65 88
27 87
76 86
41 85
8 84
59 83
29 82
1 81
54 80
29 79
6 78
61 77
41 76
23 75
7 74
65 73
52 72
41 ...

output:

8
99 50
1 21
1 81
2 10
2 28
3 14
7 30
7 74
8 84
9 24
9 47
9 93
11 19
11 31
11 46
11 48
11 91
11 95
13 15
16 26
16 66
17 34
17 49
17 67
17 89
17 97
20 22
20 64
20 68
23 38
23 39
23 75
25 35
25 63
25 69
27 44
27 50
27 87
27 99
32 62
41 43
41 51
41 57
41 71
41 85
52 60
52 72
61 77
61 96
65 73
65 88

input:

8
99 50
1 21
1 81
2 10
2 28
3 14
7 30
7 74
8 84
9 24
9 47
9 93
11 19
11 31
11 46
11 48
11 91
11 95
13 15
16 26
16 66
17 34
17 49
17 67
17 89
17 97
20 22
20 64
20 68
23 38
23 39
23 75
25 35
25 63
25 69
27 44
27 50
27 87
27 99
32 62
41 43
41 51
41 57
41 71
41 85
52 60
52 72
61 77
61 96
65 73
65 88

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
4240

Test #12:

score: 5
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1768kb

input:

7
1291

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
18 99
31 98
44 97
57 96
70 95
83 94
4 93
18 92
32 91
46 90
60 89
74 88
2 87
17 86
32 85
47 84
62 83
77 82
12 81
28 80
44 79
60 78
76 77
17 76
34 75
51 74
68 73
14 72
...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
18 99
31 98
44 97
57 96
70 95
83 94
4 93
18 92
32 91
46 90
60 89
74 88
2 87
17 86
32 85
47 84
62 83
77 82
12 81
28 80
44 79
60 78
76 77
17 76
34 75
51 74
68 73
14 72
...

output:

8
99 50
1 2
2 3
2 6
2 7
2 87
4 9
4 15
4 24
4 29
4 93
8 13
11 22
14 72
16 30
16 45
16 59
18 92
18 99
20 25
20 54
23 28
23 48
27 56
28 80
31 98
32 36
32 37
32 43
32 61
32 64
32 71
32 85
32 91
44 49
44 79
44 97
46 90
47 84
50 55
52 63
57 66
57 96
60 78
60 89
68 69
68 73
70 95
74 88
77 82
83 94

input:

8
99 50
1 2
2 3
2 6
2 7
2 87
4 9
4 15
4 24
4 29
4 93
8 13
11 22
14 72
16 30
16 45
16 59
18 92
18 99
20 25
20 54
23 28
23 48
27 56
28 80
31 98
32 36
32 37
32 43
32 61
32 64
32 71
32 85
32 91
44 49
44 79
44 97
46 90
47 84
50 55
52 63
57 66
57 96
60 78
60 89
68 69
68 73
70 95
74 88
77 82
83 94

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
1291

Subtask #2:

score: 30
Accepted

Test #13:

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

input:

1
17476204

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
61 99
6 98
77 97
5 96
7 95
17 94
69 93
19 92
5 91
76 90
21 89
80 88
59 87
35 86
5 85
57 84
37 83
50 82
45 81
62 80
71 79
54 78
5 77
5 76
69 75
5 74
5 73
52 72
5 71
23...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
61 99
6 98
77 97
5 96
7 95
17 94
69 93
19 92
5 91
76 90
21 89
80 88
59 87
35 86
5 85
57 84
37 83
50 82
45 81
62 80
71 79
54 78
5 77
5 76
69 75
5 74
5 73
52 72
5 71
23...

output:

2
99 86
1 2
1 3
1 5
1 18
1 69
5 6
5 7
5 8
5 9
5 10
5 11
5 15
5 16
5 19
5 20
5 21
5 22
5 25
5 26
5 29
5 31
5 36
5 37
5 41
5 43
5 51
5 57
5 58
5 61
5 64
5 71
5 74
5 76
5 77
5 85
5 91
5 96
6 14
6 98
7 48
7 95
10 12
10 56
10 62
12 50
13 17
13 33
16 44
17 32
17 63
17 94
19 27
19 92
21 23
21 45
21 89
22 3...

input:

2
99 86
1 2
1 3
1 5
1 18
1 69
5 6
5 7
5 8
5 9
5 10
5 11
5 15
5 16
5 19
5 20
5 21
5 22
5 25
5 26
5 29
5 31
5 36
5 37
5 41
5 43
5 51
5 57
5 58
5 61
5 64
5 71
5 74
5 76
5 77
5 85
5 91
5 96
6 14
6 98
7 48
7 95
10 12
10 56
10 62
12 50
13 17
13 33
16 44
17 32
17 63
17 94
19 27
19 92
21 23
21 45
21 89
22 3...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
17476204

Test #14:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1772kb

input:

1
11926600

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
1 99
63 98
41 97
16 96
69 95
2 94
89 93
50 92
71 91
67 90
49 89
32 88
35 87
81 86
29 85
82 84
29 83
80 82
41 81
50 80
11 79
71 78
73 77
26 76
21 75
7 74
17 73
21 72
1...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
1 99
63 98
41 97
16 96
69 95
2 94
89 93
50 92
71 91
67 90
49 89
32 88
35 87
81 86
29 85
82 84
29 83
80 82
41 81
50 80
11 79
71 78
73 77
26 76
21 75
7 74
17 73
21 72
1...

output:

2
99 86
1 2
1 3
1 5
1 6
1 8
1 9
1 11
1 15
1 21
1 26
1 29
1 36
1 41
1 50
1 51
1 57
1 71
1 99
2 32
2 94
3 30
3 59
3 62
5 7
5 12
5 23
5 45
5 67
7 74
8 10
8 22
8 64
9 17
9 33
9 65
11 14
11 16
11 27
11 31
11 40
11 54
11 66
11 79
13 18
13 69
16 20
16 56
16 96
17 19
17 25
17 37
20 24
20 70
21 72
21 75
22 4...

input:

2
99 86
1 2
1 3
1 5
1 6
1 8
1 9
1 11
1 15
1 21
1 26
1 29
1 36
1 41
1 50
1 51
1 57
1 71
1 99
2 32
2 94
3 30
3 59
3 62
5 7
5 12
5 23
5 45
5 67
7 74
8 10
8 22
8 64
9 17
9 33
9 65
11 14
11 16
11 27
11 31
11 40
11 54
11 66
11 79
13 18
13 69
16 20
16 56
16 96
17 19
17 25
17 37
20 24
20 70
21 72
21 75
22 4...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
11926600

Test #15:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1772kb

input:

1
16602378

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
3 99
53 98
43 97
84 96
5 95
19 94
59 93
66 92
79 91
52 90
35 89
82 88
79 87
9 86
31 85
55 84
3 83
52 82
59 81
55 80
1 79
24 78
27 77
4 76
35 75
62 74
43 73
23 72
59 7...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
3 99
53 98
43 97
84 96
5 95
19 94
59 93
66 92
79 91
52 90
35 89
82 88
79 87
9 86
31 85
55 84
3 83
52 82
59 81
55 80
1 79
24 78
27 77
4 76
35 75
62 74
43 73
23 72
59 7...

output:

2
99 86
1 2
1 3
1 7
1 14
1 27
1 40
1 79
2 12
3 5
3 8
3 9
3 15
3 29
3 50
3 57
3 99
4 6
4 16
4 26
4 76
5 48
5 95
7 10
7 19
7 37
8 20
9 11
9 18
9 62
9 86
10 22
11 17
11 33
11 65
13 23
13 24
13 47
13 67
13 70
14 66
15 60
19 21
19 25
19 31
19 32
19 41
19 61
19 63
19 94
23 54
23 72
24 30
24 36
24 56
24 78...

input:

2
99 86
1 2
1 3
1 7
1 14
1 27
1 40
1 79
2 12
3 5
3 8
3 9
3 15
3 29
3 50
3 57
3 99
4 6
4 16
4 26
4 76
5 48
5 95
7 10
7 19
7 37
8 20
9 11
9 18
9 62
9 86
10 22
11 17
11 33
11 65
13 23
13 24
13 47
13 67
13 70
14 66
15 60
19 21
19 25
19 31
19 32
19 41
19 61
19 63
19 94
23 54
23 72
24 30
24 36
24 56
24 78...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
16602378

Test #16:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1764kb

input:

3
13129243

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
86 99
3 98
92 97
54 96
76 95
62 94
16 93
37 92
44 91
53 90
84 89
74 88
54 87
59 86
44 85
55 84
60 83
35 82
44 81
76 80
50 79
51 78
16 77
44 76
16 75
48 74
44 73
66 72...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
86 99
3 98
92 97
54 96
76 95
62 94
16 93
37 92
44 91
53 90
84 89
74 88
54 87
59 86
44 85
55 84
60 83
35 82
44 81
76 80
50 79
51 78
16 77
44 76
16 75
48 74
44 73
66 72...

output:

4
99 50
3 98
7 12
9 36
14 16
14 31
16 20
16 24
16 29
16 30
16 38
16 39
16 47
16 59
16 75
16 77
16 93
18 23
19 26
19 42
20 25
28 33
28 65
29 34
29 48
29 56
31 32
31 54
33 60
35 58
35 82
37 50
37 92
40 45
48 74
50 79
51 78
53 90
54 87
54 96
55 84
58 68
59 86
60 83
66 72
74 88
76 80
76 95
84 89
86 99
9...

input:

4
99 50
3 98
7 12
9 36
14 16
14 31
16 20
16 24
16 29
16 30
16 38
16 39
16 47
16 59
16 75
16 77
16 93
18 23
19 26
19 42
20 25
28 33
28 65
29 34
29 48
29 56
31 32
31 54
33 60
35 58
35 82
37 50
37 92
40 45
48 74
50 79
51 78
53 90
54 87
54 96
55 84
58 68
59 86
60 83
66 72
74 88
76 80
76 95
84 89
86 99
9...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
13129243

Test #17:

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

input:

3
7892141

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
6 99
28 98
78 97
17 96
90 95
69 94
14 93
76 92
42 91
67 90
38 89
24 88
8 87
62 86
6 85
4 84
52 83
69 82
62 81
42 80
24 79
27 78
74 77
42 76
42 75
39 74
6 73
66 72
62 ...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
6 99
28 98
78 97
17 96
90 95
69 94
14 93
76 92
42 91
67 90
38 89
24 88
8 87
62 86
6 85
4 84
52 83
69 82
62 81
42 80
24 79
27 78
74 77
42 76
42 75
39 74
6 73
66 72
62 ...

output:

4
99 50
2 6
3 4
4 84
6 7
6 8
6 9
6 10
6 13
6 15
6 19
6 22
6 25
6 29
6 37
6 43
6 50
6 57
6 64
6 73
6 85
6 99
8 44
8 87
12 16
12 31
15 28
16 23
18 54
22 41
28 35
28 98
30 49
36 39
37 66
39 74
43 48
45 52
46 65
50 53
52 83
60 67
60 70
66 72
67 90
69 82
69 94
74 77
76 92
78 97
90 95

input:

4
99 50
2 6
3 4
4 84
6 7
6 8
6 9
6 10
6 13
6 15
6 19
6 22
6 25
6 29
6 37
6 43
6 50
6 57
6 64
6 73
6 85
6 99
8 44
8 87
12 16
12 31
15 28
16 23
18 54
22 41
28 35
28 98
30 49
36 39
37 66
39 74
43 48
45 52
46 65
50 53
52 83
60 67
60 70
66 72
67 90
69 82
69 94
74 77
76 92
78 97
90 95

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
7892141

Test #18:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1772kb

input:

3
21314775

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
70 99
93 98
88 97
6 96
88 95
13 94
32 93
28 92
76 91
77 90
32 89
37 88
20 87
6 86
28 85
44 84
24 83
31 82
56 81
23 80
28 79
21 78
44 77
1 76
38 75
17 74
40 73
8 72
56...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
70 99
93 98
88 97
6 96
88 95
13 94
32 93
28 92
76 91
77 90
32 89
37 88
20 87
6 86
28 85
44 84
24 83
31 82
56 81
23 80
28 79
21 78
44 77
1 76
38 75
17 74
40 73
8 72
56...

output:

4
99 50
1 4
2 3
2 14
2 27
4 5
4 7
4 10
4 13
4 19
4 28
4 37
4 55
7 22
13 94
14 15
17 74
20 44
20 87
23 60
23 80
26 51
31 46
31 54
31 82
32 45
32 47
32 89
34 62
37 88
38 75
40 49
40 52
40 69
40 73
41 48
41 66
44 63
44 77
44 84
49 64
55 70
56 57
56 71
66 68
70 99
76 91
77 90
88 95
88 97
93 98

input:

4
99 50
1 4
2 3
2 14
2 27
4 5
4 7
4 10
4 13
4 19
4 28
4 37
4 55
7 22
13 94
14 15
17 74
20 44
20 87
23 60
23 80
26 51
31 46
31 54
31 82
32 45
32 47
32 89
34 62
37 88
38 75
40 49
40 52
40 69
40 73
41 48
41 66
44 63
44 77
44 84
49 64
55 70
56 57
56 71
66 68
70 99
76 91
77 90
88 95
88 97
93 98

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
21314775

Test #19:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1764kb

input:

5
5559540

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
1 99
83 98
85 97
46 96
5 95
1 94
73 93
78 92
61 91
67 90
53 89
67 88
71 87
31 86
1 85
35 84
23 83
25 82
21 81
74 80
13 79
64 78
65 77
16 76
69 75
7 74
61 73
28 72
1 7...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
1 99
83 98
85 97
46 96
5 95
1 94
73 93
78 92
61 91
67 90
53 89
67 88
71 87
31 86
1 85
35 84
23 83
25 82
21 81
74 80
13 79
64 78
65 77
16 76
69 75
7 74
61 73
28 72
1 7...

output:

6
99 52
1 3
1 4
1 5
1 6
1 7
1 8
1 11
1 13
1 15
1 16
1 21
1 22
1 29
1 31
1 32
1 36
1 43
1 50
1 61
1 62
1 63
1 71
1 85
1 94
1 99
9 12
9 23
9 30
9 45
9 59
14 18
25 28
25 37
25 55
25 82
26 66
27 39
27 47
35 84
41 51
46 58
46 96
53 54
53 65
53 89
64 78
67 88
67 90
69 75
73 93
74 80
83 98

input:

6
99 52
1 3
1 4
1 5
1 6
1 7
1 8
1 11
1 13
1 15
1 16
1 21
1 22
1 29
1 31
1 32
1 36
1 43
1 50
1 61
1 62
1 63
1 71
1 85
1 94
1 99
9 12
9 23
9 30
9 45
9 59
14 18
25 28
25 37
25 55
25 82
26 66
27 39
27 47
35 84
41 51
46 58
46 96
53 54
53 65
53 89
64 78
67 88
67 90
69 75
73 93
74 80
83 98

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
5559540

Test #20:

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

input:

5
9424319

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
52 99
91 98
96 97
35 96
68 95
72 94
24 93
87 92
60 91
21 90
48 89
45 88
10 87
30 86
24 85
2 84
60 83
51 82
80 81
15 80
48 79
59 78
16 77
45 76
50 75
20 74
24 73
64 72...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
52 99
91 98
96 97
35 96
68 95
72 94
24 93
87 92
60 91
21 90
48 89
45 88
10 87
30 86
24 85
2 84
60 83
51 82
80 81
15 80
48 79
59 78
16 77
45 76
50 75
20 74
24 73
64 72...

output:

6
99 55
1 2
2 84
3 4
4 12
4 23
4 45
5 6
6 10
6 19
8 9
13 18
13 38
14 60
15 16
15 34
15 46
15 56
15 80
20 21
20 26
20 51
20 74
22 27
24 25
24 28
24 29
24 37
24 43
24 47
24 55
24 57
24 64
24 70
24 73
24 85
24 93
30 31
30 35
30 52
30 86
32 33
40 41
48 49
48 53
48 67
48 79
48 89
50 75
54 58
59 78
68 95
...

input:

6
99 55
1 2
2 84
3 4
4 12
4 23
4 45
5 6
6 10
6 19
8 9
13 18
13 38
14 60
15 16
15 34
15 46
15 56
15 80
20 21
20 26
20 51
20 74
22 27
24 25
24 28
24 29
24 37
24 43
24 47
24 55
24 57
24 64
24 70
24 73
24 85
24 93
30 31
30 35
30 52
30 86
32 33
40 41
48 49
48 53
48 67
48 79
48 89
50 75
54 58
59 78
68 95
...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
9424319

Test #21:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1776kb

input:

5
10955780

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
67 99
19 98
69 97
1 96
81 95
9 94
53 93
18 92
81 91
59 90
45 89
45 88
69 87
46 86
81 85
30 84
7 83
45 82
21 81
61 80
57 79
67 78
1 77
6 76
7 75
14 74
45 73
55 72
11 7...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
67 99
19 98
69 97
1 96
81 95
9 94
53 93
18 92
81 91
59 90
45 89
45 88
69 87
46 86
81 85
30 84
7 83
45 82
21 81
61 80
57 79
67 78
1 77
6 76
7 75
14 74
45 73
55 72
11 7...

output:

6
99 54
1 3
1 5
1 6
1 11
1 12
1 20
1 21
1 23
1 39
1 45
1 56
1 77
1 96
4 8
7 24
7 38
7 42
7 47
7 75
7 83
9 10
9 13
9 19
9 32
9 37
9 63
9 94
14 74
16 30
18 22
18 28
18 40
18 50
18 64
18 92
25 29
26 44
31 51
31 66
34 48
36 46
53 57
53 93
55 72
59 62
59 90
61 80
67 78
67 99
69 87
69 97
81 85
81 91
81 95

input:

6
99 54
1 3
1 5
1 6
1 11
1 12
1 20
1 21
1 23
1 39
1 45
1 56
1 77
1 96
4 8
7 24
7 38
7 42
7 47
7 75
7 83
9 10
9 13
9 19
9 32
9 37
9 63
9 94
14 74
16 30
18 22
18 28
18 40
18 50
18 64
18 92
25 29
26 44
31 51
31 66
34 48
36 46
53 57
53 93
55 72
59 62
59 90
61 80
67 78
67 99
69 87
69 97
81 85
81 91
81 95

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
10955780

Test #22:

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

input:

7
19938721

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
34 99
81 98
2 97
27 96
6 95
80 94
22 93
76 92
32 91
52 90
34 89
62 88
52 87
17 86
62 85
47 84
12 83
5 82
2 81
70 80
50 79
34 78
46 77
47 76
14 75
13 74
50 73
5 72
62 ...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
34 99
81 98
2 97
27 96
6 95
80 94
22 93
76 92
32 91
52 90
34 89
62 88
52 87
17 86
62 85
47 84
12 83
5 82
2 81
70 80
50 79
34 78
46 77
47 76
14 75
13 74
50 73
5 72
62 ...

output:

8
99 50
2 3
2 7
2 21
2 25
2 31
2 33
2 49
2 61
2 97
4 30
4 59
5 10
5 28
5 72
5 82
8 39
9 44
11 40
12 42
12 83
13 74
14 19
14 38
14 75
16 54
17 86
18 63
20 43
26 60
27 36
27 96
32 55
32 91
34 57
37 66
41 64
46 77
47 84
50 53
50 73
50 79
52 87
52 90
56 67
62 71
62 85
62 88
76 92
80 94
81 98

input:

8
99 50
2 3
2 7
2 21
2 25
2 31
2 33
2 49
2 61
2 97
4 30
4 59
5 10
5 28
5 72
5 82
8 39
9 44
11 40
12 42
12 83
13 74
14 19
14 38
14 75
16 54
17 86
18 63
20 43
26 60
27 36
27 96
32 55
32 91
34 57
37 66
41 64
46 77
47 84
50 53
50 73
50 79
52 87
52 90
56 67
62 71
62 85
62 88
76 92
80 94
81 98

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
19938721

Test #23:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1772kb

input:

7
5129508

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
91 99
52 98
37 97
79 96
23 95
1 94
49 93
21 92
49 91
83 90
77 89
76 88
39 87
14 86
49 85
26 84
81 83
22 82
69 81
39 80
73 79
77 78
41 77
34 76
51 75
18 74
13 73
43 72...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
91 99
52 98
37 97
79 96
23 95
1 94
49 93
21 92
49 91
83 90
77 89
76 88
39 87
14 86
49 85
26 84
81 83
22 82
69 81
39 80
73 79
77 78
41 77
34 76
51 75
18 74
13 73
43 72...

output:

8
99 50
3 20
3 24
3 47
4 6
4 10
4 16
4 46
7 8
7 15
7 43
8 14
9 26
9 51
10 54
11 12
13 25
13 73
14 36
14 38
14 86
18 30
18 74
19 62
22 28
22 58
22 82
23 48
23 95
26 84
29 41
31 35
33 45
40 42
42 50
43 72
44 56
47 59
51 75
52 98
55 67
56 68
65 69
73 79
76 88
77 78
77 89
79 96
81 83
83 90
91 99

input:

8
99 50
3 20
3 24
3 47
4 6
4 10
4 16
4 46
7 8
7 15
7 43
8 14
9 26
9 51
10 54
11 12
13 25
13 73
14 36
14 38
14 86
18 30
18 74
19 62
22 28
22 58
22 82
23 48
23 95
26 84
29 41
31 35
33 45
40 42
42 50
43 72
44 56
47 59
51 75
52 98
55 67
56 68
65 69
73 79
76 88
77 78
77 89
79 96
81 83
83 90
91 99

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
5129508

Test #24:

score: 30
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1764kb

input:

7
15332941

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
58 99
55 98
14 97
37 96
38 95
32 94
38 93
79 92
2 91
22 90
86 89
62 88
2 87
47 86
2 85
20 84
8 83
47 82
62 81
69 80
14 79
9 78
18 77
17 76
68 75
22 74
38 73
66 72
2 7...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
58 99
55 98
14 97
37 96
38 95
32 94
38 93
79 92
2 91
22 90
86 89
62 88
2 87
47 86
2 85
20 84
8 83
47 82
62 81
69 80
14 79
9 78
18 77
17 76
68 75
22 74
38 73
66 72
2 7...

output:

8
99 50
2 3
2 5
2 7
2 10
2 11
2 16
2 19
2 21
2 29
2 36
2 44
2 46
2 61
2 64
2 71
2 85
2 87
2 91
9 12
9 50
9 78
14 25
14 40
14 49
14 65
15 24
18 39
18 77
20 23
20 28
20 34
20 67
20 84
30 35
30 57
37 96
38 48
38 70
38 73
38 93
38 95
47 52
47 82
55 98
58 99
66 72
68 75
69 80
79 92
86 89

input:

8
99 50
2 3
2 5
2 7
2 10
2 11
2 16
2 19
2 21
2 29
2 36
2 44
2 46
2 61
2 64
2 71
2 85
2 87
2 91
9 12
9 50
9 78
14 25
14 40
14 49
14 65
15 24
18 39
18 77
20 23
20 28
20 34
20 67
20 84
30 35
30 57
37 96
38 48
38 70
38 73
38 93
38 95
47 52
47 82
55 98
58 99
66 72
68 75
69 80
79 92
86 89

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
15332941

Subtask #3:

score: 65
Accepted

Test #25:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1772kb

input:

1
355365355024496523

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
22 99
73 98
76 97
19 96
30 95
7 94
56 93
71 92
4 91
56 90
4 89
40 88
62 87
49 86
64 85
10 84
60 83
67 82
44 81
78 80
58 79
15 78
76 77
49 76
10 75
32 74
4 73
71 72
64...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
22 99
73 98
76 97
19 96
30 95
7 94
56 93
71 92
4 91
56 90
4 89
40 88
62 87
49 86
64 85
10 84
60 83
67 82
44 81
78 80
58 79
15 78
76 77
49 76
10 75
32 74
4 73
71 72
64...

output:

2
99 86
1 2
1 8
1 22
2 3
4 5
4 6
4 7
4 9
4 10
4 11
4 12
4 16
4 19
4 21
4 23
4 25
4 31
4 37
4 41
4 45
4 56
4 61
4 67
4 89
4 91
6 14
6 27
6 54
7 32
7 94
8 15
8 29
10 24
10 47
10 70
10 75
10 84
11 30
12 17
12 33
12 65
13 28
15 18
15 78
19 20
19 40
19 44
19 58
19 66
19 96
22 43
22 50
22 64
22 99
24 26
2...

input:

2
99 86
1 2
1 8
1 22
2 3
4 5
4 6
4 7
4 9
4 10
4 11
4 12
4 16
4 19
4 21
4 23
4 25
4 31
4 37
4 41
4 45
4 56
4 61
4 67
4 89
4 91
6 14
6 27
6 54
7 32
7 94
8 15
8 29
10 24
10 47
10 70
10 75
10 84
11 30
12 17
12 33
12 65
13 28
15 18
15 78
19 20
19 40
19 44
19 58
19 66
19 96
22 43
22 50
22 64
22 99
24 26
2...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
355365355024496523

Test #26:

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

input:

1
727827999106414164

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
43 99
94 98
85 97
90 96
89 95
55 94
69 93
50 92
25 91
18 90
69 89
49 88
41 87
80 86
1 85
57 84
73 83
79 82
5 81
79 80
37 79
36 78
33 77
40 76
19 75
66 74
61 73
56 72
...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
43 99
94 98
85 97
90 96
89 95
55 94
69 93
50 92
25 91
18 90
69 89
49 88
41 87
80 86
1 85
57 84
73 83
79 82
5 81
79 80
37 79
36 78
33 77
40 76
19 75
66 74
61 73
56 72
...

output:

2
99 86
1 2
1 3
1 5
1 7
1 8
1 15
1 22
1 29
1 43
1 85
3 12
3 23
4 62
5 6
5 9
5 11
5 17
5 21
5 41
5 81
7 10
7 19
10 16
11 14
11 27
12 18
13 25
14 20
15 26
15 36
15 51
15 71
18 90
19 75
20 30
21 33
21 65
23 24
23 47
24 32
25 28
25 31
25 37
25 45
25 55
25 56
25 61
25 67
25 91
29 57
29 69
30 54
33 77
36 ...

input:

2
99 86
1 2
1 3
1 5
1 7
1 8
1 15
1 22
1 29
1 43
1 85
3 12
3 23
4 62
5 6
5 9
5 11
5 17
5 21
5 41
5 81
7 10
7 19
10 16
11 14
11 27
12 18
13 25
14 20
15 26
15 36
15 51
15 71
18 90
19 75
20 30
21 33
21 65
23 24
23 47
24 32
25 28
25 31
25 37
25 45
25 55
25 56
25 61
25 67
25 91
29 57
29 69
30 54
33 77
36 ...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
727827999106414164

Test #27:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1772kb

input:

1
656410143989222955

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
18 99
58 98
76 97
16 96
88 95
25 94
56 93
60 92
46 91
89 90
36 89
79 88
30 87
36 86
4 85
1 84
50 83
1 82
76 81
59 80
34 79
25 78
16 77
31 76
46 75
5 74
28 73
38 72
46...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
18 99
58 98
76 97
16 96
88 95
25 94
56 93
60 92
46 91
89 90
36 89
79 88
30 87
36 86
4 85
1 84
50 83
1 82
76 81
59 80
34 79
25 78
16 77
31 76
46 75
5 74
28 73
38 72
46...

output:

2
99 86
1 2
1 6
1 10
1 16
1 28
1 82
1 84
2 3
2 18
3 12
4 5
4 7
4 8
4 9
4 15
4 22
4 25
4 29
4 43
4 57
4 85
5 74
6 11
6 26
6 51
7 54
8 14
8 27
8 53
10 19
10 24
10 47
10 70
11 36
12 17
12 33
14 23
16 20
16 21
16 31
16 58
16 61
16 77
16 96
18 50
18 99
19 52
21 30
21 66
23 60
24 62
25 32
25 78
25 94
28 3...

input:

2
99 86
1 2
1 6
1 10
1 16
1 28
1 82
1 84
2 3
2 18
3 12
4 5
4 7
4 8
4 9
4 15
4 22
4 25
4 29
4 43
4 57
4 85
5 74
6 11
6 26
6 51
7 54
8 14
8 27
8 53
10 19
10 24
10 47
10 70
11 36
12 17
12 33
14 23
16 20
16 21
16 31
16 58
16 61
16 77
16 96
18 50
18 99
19 52
21 30
21 66
23 60
24 62
25 32
25 78
25 94
28 3...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
656410143989222955

Test #28:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1776kb

input:

1
410366615149657534

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
89 99
60 98
95 97
85 96
93 95
71 94
3 93
5 92
5 91
49 90
39 89
41 88
21 87
50 86
47 85
19 84
19 83
32 82
15 81
64 80
5 79
61 78
47 77
35 76
31 75
1 74
23 73
3 72
5 71...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
89 99
60 98
95 97
85 96
93 95
71 94
3 93
5 92
5 91
49 90
39 89
41 88
21 87
50 86
47 85
19 84
19 83
32 82
15 81
64 80
5 79
61 78
47 77
35 76
31 75
1 74
23 73
3 72
5 71...

output:

2
99 86
1 2
1 3
1 74
3 5
3 24
3 47
3 54
3 72
3 93
5 6
5 7
5 8
5 10
5 11
5 14
5 15
5 16
5 19
5 22
5 27
5 28
5 31
5 36
5 40
5 43
5 55
5 64
5 66
5 71
5 79
5 91
5 92
6 12
7 9
9 20
9 32
9 63
10 26
12 30
15 17
15 21
15 41
15 81
16 18
17 23
17 67
19 29
19 84
21 44
21 87
23 25
23 37
24 62
26 70
31 33
31 53
...

input:

2
99 86
1 2
1 3
1 74
3 5
3 24
3 47
3 54
3 72
3 93
5 6
5 7
5 8
5 10
5 11
5 14
5 15
5 16
5 19
5 22
5 27
5 28
5 31
5 36
5 40
5 43
5 55
5 64
5 66
5 71
5 79
5 91
5 92
6 12
7 9
9 20
9 32
9 63
10 26
12 30
15 17
15 21
15 41
15 81
16 18
17 23
17 67
19 29
19 84
21 44
21 87
23 25
23 37
24 62
26 70
31 33
31 53
...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
410366615149657534

Test #29:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1772kb

input:

1
298090682780948428

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
1 99
41 98
77 97
69 96
37 95
32 94
5 93
8 92
59 91
87 90
53 89
23 88
21 87
49 86
29 85
18 84
37 83
41 82
29 81
70 80
47 79
64 78
69 77
29 76
45 75
50 74
5 73
41 72
29...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
99
1 99
41 98
77 97
69 96
37 95
32 94
5 93
8 92
59 91
87 90
53 89
23 88
21 87
49 86
29 85
18 84
37 83
41 82
29 81
70 80
47 79
64 78
69 77
29 76
45 75
50 74
5 73
41 72
29...

output:

2
99 86
1 2
1 3
1 5
1 8
1 15
1 29
1 32
1 50
1 63
1 99
4 6
4 26
5 7
5 9
5 10
5 19
5 24
5 25
5 37
5 47
5 70
5 93
8 14
8 22
8 40
8 92
9 11
9 12
9 21
9 23
9 45
9 56
9 60
12 20
13 17
13 33
13 65
14 16
14 28
15 18
18 84
21 27
21 44
21 53
21 87
23 30
23 59
29 31
29 36
29 41
29 43
29 49
29 51
29 57
29 61
29...

input:

2
99 86
1 2
1 3
1 5
1 8
1 15
1 29
1 32
1 50
1 63
1 99
4 6
4 26
5 7
5 9
5 10
5 19
5 24
5 25
5 37
5 47
5 70
5 93
8 14
8 22
8 40
8 92
9 11
9 12
9 21
9 23
9 45
9 56
9 60
12 20
13 17
13 33
13 65
14 16
14 28
15 18
18 84
21 27
21 44
21 53
21 87
23 30
23 59
29 31
29 36
29 41
29 43
29 49
29 51
29 57
29 61
29...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
298090682780948428

Test #30:

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

input:

3
969441916331132577

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
68 99
82 98
34 97
13 96
50 95
31 94
70 93
61 92
28 91
67 90
26 89
67 88
84 87
23 86
82 85
44 84
50 83
19 82
18 81
57 80
22 79
26 78
70 77
28 76
74 75
13 74
10 73
43 7...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
68 99
82 98
34 97
13 96
50 95
31 94
70 93
61 92
28 91
67 90
26 89
67 88
84 87
23 86
82 85
44 84
50 83
19 82
18 81
57 80
22 79
26 78
70 77
28 76
74 75
13 74
10 73
43 7...

output:

4
99 50
1 4
4 7
4 12
4 23
4 34
4 67
5 8
7 62
8 11
12 15
16 68
18 21
18 41
23 86
24 47
31 32
31 94
32 39
33 36
34 49
34 65
34 97
37 38
38 59
40 43
40 52
41 44
43 72
44 84
45 54
46 55
48 56
48 66
50 83
50 95
51 60
57 80
58 61
61 92
62 63
67 88
67 90
68 71
68 99
70 77
70 93
74 75
82 85
82 98
84 87

input:

4
99 50
1 4
4 7
4 12
4 23
4 34
4 67
5 8
7 62
8 11
12 15
16 68
18 21
18 41
23 86
24 47
31 32
31 94
32 39
33 36
34 49
34 65
34 97
37 38
38 59
40 43
40 52
41 44
43 72
44 84
45 54
46 55
48 56
48 66
50 83
50 95
51 60
57 80
58 61
61 92
62 63
67 88
67 90
68 71
68 99
70 77
70 93
74 75
82 85
82 98
84 87

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
969441916331132577

Test #31:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1764kb

input:

3
929489812741933634

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
31 99
2 98
3 97
5 96
13 95
69 94
59 93
10 92
75 91
66 90
27 89
39 88
13 87
35 86
3 85
18 84
59 83
30 82
35 81
10 80
75 79
38 78
43 77
60 76
25 75
70 74
3 73
65 72
45 ...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
31 99
2 98
3 97
5 96
13 95
69 94
59 93
10 92
75 91
66 90
27 89
39 88
13 87
35 86
3 85
18 84
59 83
30 82
35 81
10 80
75 79
38 78
43 77
60 76
25 75
70 74
3 73
65 72
45 ...

output:

4
99 50
1 3
2 98
3 4
3 5
3 7
3 8
3 9
3 10
3 13
3 15
3 19
3 22
3 25
3 28
3 29
3 33
3 37
3 43
3 49
3 55
3 57
3 64
3 65
3 73
3 85
3 97
14 54
24 58
30 46
31 50
31 99
36 40
36 70
38 78
39 59
39 88
43 77
45 62
45 71
51 68
52 60
59 83
59 93
60 76
65 72
66 90
69 94
70 74
75 79
75 91

input:

4
99 50
1 3
2 98
3 4
3 5
3 7
3 8
3 9
3 10
3 13
3 15
3 19
3 22
3 25
3 28
3 29
3 33
3 37
3 43
3 49
3 55
3 57
3 64
3 65
3 73
3 85
3 97
14 54
24 58
30 46
31 50
31 99
36 40
36 70
38 78
39 59
39 88
43 77
45 62
45 71
51 68
52 60
59 83
59 93
60 76
65 72
66 90
69 94
70 74
75 79
75 91

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
929489812741933634

Test #32:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1764kb

input:

3
144032041325838295

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
22 99
35 98
56 97
81 96
74 95
53 94
80 93
85 92
56 91
13 90
48 89
5 88
4 87
61 86
8 85
41 84
44 83
29 82
56 81
54 80
20 79
15 78
24 77
71 76
48 75
64 74
56 73
47 72
3...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
22 99
35 98
56 97
81 96
74 95
53 94
80 93
85 92
56 91
13 90
48 89
5 88
4 87
61 86
8 85
41 84
44 83
29 82
56 81
54 80
20 79
15 78
24 77
71 76
48 75
64 74
56 73
47 72
3...

output:

4
99 50
1 6
1 8
3 42
5 30
5 88
7 14
8 9
8 13
8 15
8 22
8 25
8 29
8 43
8 49
8 57
8 85
10 18
10 35
13 90
15 78
16 21
16 41
21 54
25 62
27 48
29 64
29 82
34 47
34 59
35 98
36 71
41 84
44 52
44 69
44 83
46 51
46 66
47 72
48 75
48 89
50 68
53 94
54 80
61 86
64 74
71 76
74 95
80 93
81 96
85 92

input:

4
99 50
1 6
1 8
3 42
5 30
5 88
7 14
8 9
8 13
8 15
8 22
8 25
8 29
8 43
8 49
8 57
8 85
10 18
10 35
13 90
15 78
16 21
16 41
21 54
25 62
27 48
29 64
29 82
34 47
34 59
35 98
36 71
41 84
44 52
44 69
44 83
46 51
46 66
47 72
48 75
48 89
50 68
53 94
54 80
61 86
64 74
71 76
74 95
80 93
81 96
85 92

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
144032041325838295

Test #33:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1768kb

input:

3
832110946250826180

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
9 99
18 98
37 97
76 96
33 95
13 94
41 93
30 92
31 91
58 90
5 89
52 88
13 87
71 86
37 85
48 84
1 83
13 82
21 81
44 80
43 79
16 78
57 77
31 76
37 75
66 74
13 73
39 72
5...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
9 99
18 98
37 97
76 96
33 95
13 94
41 93
30 92
31 91
58 90
5 89
52 88
13 87
71 86
37 85
48 84
1 83
13 82
21 81
44 80
43 79
16 78
57 77
31 76
37 75
66 74
13 73
39 72
5...

output:

4
99 50
1 2
1 3
1 4
1 5
1 6
1 7
1 11
1 13
1 16
1 21
1 31
1 42
1 61
1 83
2 8
3 18
3 35
6 26
17 27
17 53
18 24
18 98
19 20
19 58
21 41
23 30
23 59
29 62
30 92
33 48
33 95
35 60
38 68
39 72
41 47
41 93
43 79
44 80
48 84
49 67
51 71
52 88
56 66
57 77
58 64
58 90
64 70
66 74
71 86
76 96

input:

4
99 50
1 2
1 3
1 4
1 5
1 6
1 7
1 11
1 13
1 16
1 21
1 31
1 42
1 61
1 83
2 8
3 18
3 35
6 26
17 27
17 53
18 24
18 98
19 20
19 58
21 41
23 30
23 59
29 62
30 92
33 48
33 95
35 60
38 68
39 72
41 47
41 93
43 79
44 80
48 84
49 67
51 71
52 88
56 66
57 77
58 64
58 90
64 70
66 74
71 86
76 96

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
832110946250826180

Test #34:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1768kb

input:

3
85728715707691821

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
10 99
28 98
46 97
7 96
12 95
67 94
54 93
38 92
22 91
40 90
62 89
82 88
54 87
82 86
10 85
74 84
44 83
22 82
62 81
3 80
64 79
73 78
26 77
22 76
48 75
8 74
22 73
37 72
5...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
3
99
10 99
28 98
46 97
7 96
12 95
67 94
54 93
38 92
22 91
40 90
62 89
82 88
54 87
82 86
10 85
74 84
44 83
22 82
62 81
3 80
64 79
73 78
26 77
22 76
48 75
8 74
22 73
37 72
5...

output:

4
99 50
5 32
6 9
10 22
11 38
11 44
17 36
18 23
18 45
22 25
22 26
22 28
22 31
22 37
22 41
22 46
22 51
22 55
22 61
22 73
22 76
22 82
22 91
24 30
24 59
25 40
26 39
26 77
28 98
34 62
36 63
37 72
40 67
40 90
41 54
44 83
46 49
46 65
46 97
48 60
48 75
52 71
54 87
54 93
62 89
64 79
67 94
73 78
74 84
82 86
8...

input:

4
99 50
5 32
6 9
10 22
11 38
11 44
17 36
18 23
18 45
22 25
22 26
22 28
22 31
22 37
22 41
22 46
22 51
22 55
22 61
22 73
22 76
22 82
22 91
24 30
24 59
25 40
26 39
26 77
28 98
34 62
36 63
37 72
40 67
40 90
41 54
44 83
46 49
46 65
46 97
48 60
48 75
52 71
54 87
54 93
62 89
64 79
67 94
73 78
74 84
82 86
8...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
85728715707691821

Test #35:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1772kb

input:

5
777434612360931036

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
93 99
21 98
61 97
42 96
13 95
19 94
73 93
58 92
37 91
63 90
29 89
31 88
71 87
82 86
37 85
28 84
33 83
73 82
77 81
66 80
19 79
51 78
61 77
37 76
43 75
61 74
37 73
38 7...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
93 99
21 98
61 97
42 96
13 95
19 94
73 93
58 92
37 91
63 90
29 89
31 88
71 87
82 86
37 85
28 84
33 83
73 82
77 81
66 80
19 79
51 78
61 77
37 76
43 75
61 74
37 73
38 7...

output:

6
99 57
1 3
2 6
2 8
2 30
2 36
2 62
4 20
4 24
4 58
4 70
5 9
7 11
7 12
7 16
7 23
7 31
7 34
7 56
7 67
13 17
13 25
13 48
13 49
13 95
14 18
19 27
19 28
19 32
19 40
19 55
19 63
19 79
19 94
21 98
29 33
29 45
29 65
29 89
37 41
37 43
37 46
37 51
37 57
37 61
37 64
37 71
37 73
37 76
37 85
37 91
38 72
42 96
44 ...

input:

6
99 57
1 3
2 6
2 8
2 30
2 36
2 62
4 20
4 24
4 58
4 70
5 9
7 11
7 12
7 16
7 23
7 31
7 34
7 56
7 67
13 17
13 25
13 48
13 49
13 95
14 18
19 27
19 28
19 32
19 40
19 55
19 63
19 79
19 94
21 98
29 33
29 45
29 65
29 89
37 41
37 43
37 46
37 51
37 57
37 61
37 64
37 71
37 73
37 76
37 85
37 91
38 72
42 96
44 ...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
777434612360931036

Test #36:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1768kb,1772kb

input:

5
705262511549880222

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
23 99
49 98
31 97
73 96
53 95
31 94
11 93
30 92
43 91
76 90
71 89
22 88
29 87
83 86
79 85
73 84
5 83
25 82
63 81
37 80
43 79
16 78
35 77
73 76
59 75
49 74
7 73
20 72
...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
23 99
49 98
31 97
73 96
53 95
31 94
11 93
30 92
43 91
76 90
71 89
22 88
29 87
83 86
79 85
73 84
5 83
25 82
63 81
37 80
43 79
16 78
35 77
73 76
59 75
49 74
7 73
20 72
...

output:

6
99 55
1 2
3 5
3 6
3 11
3 21
4 14
4 40
7 9
7 10
7 13
7 19
7 25
7 37
7 73
12 62
15 17
15 18
15 35
15 69
16 20
16 22
16 34
16 58
16 64
16 78
23 26
23 29
23 36
23 41
23 50
23 51
23 57
23 71
23 99
27 45
30 92
31 32
31 33
31 49
31 63
31 65
31 94
31 97
38 56
42 54
43 46
43 53
43 61
43 66
43 79
43 91
48 6...

input:

6
99 55
1 2
3 5
3 6
3 11
3 21
4 14
4 40
7 9
7 10
7 13
7 19
7 25
7 37
7 73
12 62
15 17
15 18
15 35
15 69
16 20
16 22
16 34
16 58
16 64
16 78
23 26
23 29
23 36
23 41
23 50
23 51
23 57
23 71
23 99
27 45
30 92
31 32
31 33
31 49
31 63
31 65
31 94
31 97
38 56
42 54
43 46
43 53
43 61
43 66
43 79
43 91
48 6...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
705262511549880222

Test #37:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1772kb

input:

5
510318082834167951

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
64 99
84 98
16 97
57 96
90 95
13 94
40 93
71 92
82 91
70 90
80 89
43 88
84 87
17 86
64 85
32 84
76 83
1 82
32 81
25 80
58 79
36 78
76 77
52 76
14 75
60 74
64 73
18 72...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
64 99
84 98
16 97
57 96
90 95
13 94
40 93
71 92
82 91
70 90
80 89
43 88
84 87
17 86
64 85
32 84
76 83
1 82
32 81
25 80
58 79
36 78
76 77
52 76
14 75
60 74
64 73
18 72...

output:

6
99 55
1 4
2 3
2 6
2 11
2 26
2 51
4 7
4 13
4 68
8 9
8 15
8 29
8 57
10 19
12 21
14 23
14 30
14 38
14 59
14 75
16 17
16 25
16 33
16 49
16 65
16 97
18 72
22 31
22 36
22 43
22 71
24 60
28 37
28 55
32 41
32 53
32 66
32 81
32 84
34 35
34 52
40 47
40 70
40 93
44 63
58 67
58 79
64 73
64 85
64 99
76 77
76 8...

input:

6
99 55
1 4
2 3
2 6
2 11
2 26
2 51
4 7
4 13
4 68
8 9
8 15
8 29
8 57
10 19
12 21
14 23
14 30
14 38
14 59
14 75
16 17
16 25
16 33
16 49
16 65
16 97
18 72
22 31
22 36
22 43
22 71
24 60
28 37
28 55
32 41
32 53
32 66
32 81
32 84
34 35
34 52
40 47
40 70
40 93
44 63
58 67
58 79
64 73
64 85
64 99
76 77
76 8...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
510318082834167951

Test #38:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1768kb

input:

5
914858813253258744

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
53 99
15 98
25 97
15 96
19 95
85 94
9 93
53 92
25 91
36 90
25 89
10 88
67 87
5 86
25 85
64 84
9 83
34 82
25 81
20 80
1 79
25 78
53 77
70 76
67 75
69 74
25 73
54 72
25...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
53 99
15 98
25 97
15 96
19 95
85 94
9 93
53 92
25 91
36 90
25 89
10 88
67 87
5 86
25 85
64 84
9 83
34 82
25 81
20 80
1 79
25 78
53 77
70 76
67 75
69 74
25 73
54 72
25...

output:

6
99 60
1 2
3 12
3 23
4 8
4 22
4 50
5 6
5 11
5 18
5 21
5 35
5 69
5 86
7 10
7 19
7 28
7 55
9 17
9 24
9 42
9 47
9 62
9 83
9 93
15 20
15 39
15 96
15 98
25 29
25 31
25 33
25 34
25 36
25 37
25 41
25 43
25 45
25 46
25 49
25 56
25 57
25 61
25 64
25 67
25 71
25 73
25 78
25 81
25 85
25 89
25 91
25 97
30 38
3...

input:

6
99 60
1 2
3 12
3 23
4 8
4 22
4 50
5 6
5 11
5 18
5 21
5 35
5 69
5 86
7 10
7 19
7 28
7 55
9 17
9 24
9 42
9 47
9 62
9 83
9 93
15 20
15 39
15 96
15 98
25 29
25 31
25 33
25 34
25 36
25 37
25 41
25 43
25 45
25 46
25 49
25 56
25 57
25 61
25 64
25 67
25 71
25 73
25 78
25 81
25 85
25 89
25 91
25 97
30 38
3...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
914858813253258744

Test #39:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1768kb

input:

5
659635316746638238

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
49 99
23 98
95 97
4 96
23 95
86 94
71 93
7 92
29 91
46 90
7 89
29 88
69 87
39 86
35 85
80 84
73 83
74 82
79 81
34 80
59 79
7 78
23 77
14 76
51 75
20 74
47 73
21 72
49...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
5
99
49 99
23 98
95 97
4 96
23 95
86 94
71 93
7 92
29 91
46 90
7 89
29 88
69 87
39 86
35 85
80 84
73 83
74 82
79 81
34 80
59 79
7 78
23 77
14 76
51 75
20 74
47 73
21 72
49...

output:

6
99 53
1 2
2 10
2 24
2 70
3 5
4 6
7 8
7 9
7 12
7 14
7 15
7 23
7 27
7 29
7 45
7 53
7 57
7 78
7 89
7 92
11 13
11 19
11 37
20 28
20 40
20 74
21 72
22 68
25 47
26 44
31 33
31 65
32 42
34 80
35 43
35 85
39 41
39 51
39 69
39 86
46 90
49 50
49 71
49 99
52 54
55 63
56 62
56 64
59 61
59 66
59 79
73 83
95 97

input:

6
99 53
1 2
2 10
2 24
2 70
3 5
4 6
7 8
7 9
7 12
7 14
7 15
7 23
7 27
7 29
7 45
7 53
7 57
7 78
7 89
7 92
11 13
11 19
11 37
20 28
20 40
20 74
21 72
22 68
25 47
26 44
31 33
31 65
32 42
34 80
35 43
35 85
39 41
39 51
39 69
39 86
46 90
49 50
49 71
49 99
52 54
55 63
56 62
56 64
59 61
59 66
59 79
73 83
95 97

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
659635316746638238

Test #40:

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

input:

7
858490260563149759

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
14 99
37 98
32 97
60 96
58 95
74 94
40 93
91 92
20 91
25 90
40 89
20 88
22 87
15 86
56 85
10 84
28 83
29 82
80 81
14 80
26 79
7 78
60 77
35 76
46 75
55 74
56 73
7 72
...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
14 99
37 98
32 97
60 96
58 95
74 94
40 93
91 92
20 91
25 90
40 89
20 88
22 87
15 86
56 85
10 84
28 83
29 82
80 81
14 80
26 79
7 78
60 77
35 76
46 75
55 74
56 73
7 72
...

output:

8
99 50
5 6
9 38
10 51
10 84
11 48
12 63
14 43
14 50
14 99
15 86
17 24
17 54
18 23
20 46
22 39
22 44
22 87
25 90
26 27
26 79
28 42
28 83
29 34
29 82
31 68
32 33
32 49
32 69
32 97
35 36
35 76
37 98
40 45
40 47
40 89
40 93
46 75
52 53
56 57
56 73
56 85
58 95
60 77
60 96
62 67
65 66
70 71
74 94
80 81
9...

input:

8
99 50
5 6
9 38
10 51
10 84
11 48
12 63
14 43
14 50
14 99
15 86
17 24
17 54
18 23
20 46
22 39
22 44
22 87
25 90
26 27
26 79
28 42
28 83
29 34
29 82
31 68
32 33
32 49
32 69
32 97
35 36
35 76
37 98
40 45
40 47
40 89
40 93
46 75
52 53
56 57
56 73
56 85
58 95
60 77
60 96
62 67
65 66
70 71
74 94
80 81
9...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
858490260563149759

Test #41:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1772kb,1768kb

input:

7
860058643727731209

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
98 99
83 98
10 97
5 96
94 95
13 94
6 93
35 92
70 91
41 90
26 89
64 88
2 87
75 86
70 85
60 84
58 83
70 82
10 81
22 80
22 79
70 78
62 77
10 76
10 75
11 74
34 73
28 72
7...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
98 99
83 98
10 97
5 96
94 95
13 94
6 93
35 92
70 91
41 90
26 89
64 88
2 87
75 86
70 85
60 84
58 83
70 82
10 81
22 80
22 79
70 78
62 77
10 76
10 75
11 74
34 73
28 72
7...

output:

8
99 50
2 3
2 87
4 12
4 23
4 67
5 20
5 96
6 30
6 59
6 93
7 8
7 18
10 31
10 33
10 38
10 51
10 61
10 65
10 76
10 81
10 97
11 74
15 56
21 54
22 27
22 40
22 53
22 68
22 79
22 80
25 46
28 72
35 36
35 92
41 90
42 57
44 63
47 48
49 50
60 84
62 77
64 88
70 71
70 78
70 82
70 85
70 91
75 86
94 95
98 99

input:

8
99 50
2 3
2 87
4 12
4 23
4 67
5 20
5 96
6 30
6 59
6 93
7 8
7 18
10 31
10 33
10 38
10 51
10 61
10 65
10 76
10 81
10 97
11 74
15 56
21 54
22 27
22 40
22 53
22 68
22 79
22 80
25 46
28 72
35 36
35 92
41 90
42 57
44 63
47 48
49 50
60 84
62 77
64 88
70 71
70 78
70 82
70 85
70 91
75 86
94 95
98 99

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
860058643727731209

Test #42:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1768kb

input:

7
718861404514377808

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
97 99
51 98
17 97
29 96
39 95
41 94
37 93
48 92
29 91
7 90
25 89
23 88
21 87
64 86
41 85
29 84
13 83
38 82
49 81
15 80
35 79
69 78
29 77
59 76
57 75
21 74
65 73
28 72...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
97 99
51 98
17 97
29 96
39 95
41 94
37 93
48 92
29 91
7 90
25 89
23 88
21 87
64 86
41 85
29 84
13 83
38 82
49 81
15 80
35 79
69 78
29 77
59 76
57 75
21 74
65 73
28 72...

output:

8
99 50
3 12
6 8
7 90
10 32
11 19
14 16
14 24
14 56
14 70
15 80
17 33
20 22
21 44
21 74
21 87
23 30
23 88
25 45
25 89
28 72
29 31
29 46
29 77
29 96
34 36
35 79
37 93
38 82
39 95
40 54
41 43
41 63
41 85
41 94
47 52
47 67
48 50
48 92
49 81
51 98
55 60
57 75
58 62
59 76
61 68
64 86
65 73
69 71
69 78
97...

input:

8
99 50
3 12
6 8
7 90
10 32
11 19
14 16
14 24
14 56
14 70
15 80
17 33
20 22
21 44
21 74
21 87
23 30
23 88
25 45
25 89
28 72
29 31
29 46
29 77
29 96
34 36
35 79
37 93
38 82
39 95
40 54
41 43
41 63
41 85
41 94
47 52
47 67
48 50
48 92
49 81
51 98
55 60
57 75
58 62
59 76
61 68
64 86
65 73
69 71
69 78
97...

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
718861404514377808

Test #43:

score: 65
Accepted
time: 0ms = 0ms + 0ms
memory: 1764kb,1768kb

input:

7
659192688464047828

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
91 99
8 98
53 97
94 96
93 95
29 94
37 93
91 92
89 91
56 90
69 89
14 88
41 87
24 86
77 85
59 84
81 83
71 82
69 81
21 80
65 79
14 78
37 77
29 76
67 75
58 74
53 73
6 72
...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
91 99
8 98
53 97
94 96
93 95
29 94
37 93
91 92
89 91
56 90
69 89
14 88
41 87
24 86
77 85
59 84
81 83
71 82
69 81
21 80
65 79
14 78
37 77
29 76
67 75
58 74
53 73
6 72
...

output:

8
99 50
1 2
2 4
3 12
3 23
4 6
4 26
6 72
7 15
8 10
8 98
9 11
13 27
13 54
14 16
14 22
14 36
17 19
17 28
17 55
18 20
24 86
25 45
30 38
39 66
41 52
41 87
42 50
43 59
46 48
47 62
47 67
53 73
53 97
56 58
56 90
58 74
59 60
59 84
65 79
67 75
69 81
69 89
71 82
77 85
81 83
89 91
91 92
91 99
93 95
94 96

input:

8
99 50
1 2
2 4
3 12
3 23
4 6
4 26
6 72
7 15
8 10
8 98
9 11
13 27
13 54
14 16
14 22
14 36
17 19
17 28
17 55
18 20
24 86
25 45
30 38
39 66
41 52
41 87
42 50
43 59
46 48
47 62
47 67
53 73
53 97
56 58
56 90
58 74
59 60
59 84
65 79
67 75
69 81
69 89
71 82
77 85
81 83
89 91
91 92
91 99
93 95
94 96

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
659192688464047828

Test #44:

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

input:

7
685730986714800201

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
8 99
90 98
10 97
52 96
56 95
7 94
82 93
85 92
22 91
57 90
66 89
31 88
2 87
42 86
22 85
47 84
52 83
40 82
42 81
5 80
46 79
22 78
14 77
52 76
10 75
7 74
58 73
13 72
22 ...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
7
99
8 99
90 98
10 97
52 96
56 95
7 94
82 93
85 92
22 91
57 90
66 89
31 88
2 87
42 86
22 85
47 84
52 83
40 82
42 81
5 80
46 79
22 78
14 77
52 76
10 75
7 74
58 73
13 72
22 ...

output:

8
99 50
2 3
2 6
2 21
2 26
2 30
2 41
2 44
2 51
2 59
2 87
4 19
5 80
9 48
13 24
13 28
13 70
13 72
14 39
14 77
17 68
20 27
22 23
22 29
22 34
22 37
22 43
22 45
22 60
22 61
22 64
22 67
22 71
22 78
22 91
31 88
38 63
42 69
42 81
47 84
52 76
52 83
52 96
53 54
55 62
56 95
58 73
66 89
82 93
85 92
90 98

input:

8
99 50
2 3
2 6
2 21
2 26
2 30
2 41
2 44
2 51
2 59
2 87
4 19
5 80
9 48
13 24
13 28
13 70
13 72
14 39
14 77
17 68
20 27
22 23
22 29
22 34
22 37
22 43
22 45
22 60
22 61
22 64
22 67
22 71
22 78
22 91
31 88
38 63
42 69
42 81
47 84
52 76
52 83
52 96
53 54
55 62
56 95
58 73
66 89
82 93
85 92
90 98

output:

08e2277017156c65e2df558ef1d27eae814767ea6a771d5be687d4040371b97399dd6bd28d5207cce21e4e205ea711c730f7ccf85a21af8c41bab7c037b89e9e
685730986714800201