#1734. 显而易见的数论

显而易见的数论

Description

image

Format

Input

image

Output

image

Samples

input 1
1
3 3
0 1 2

input 2
2
5 4
4 1 5 2

input 3
3
7 5
12 11 45 6 2
output 1

4

output 2
31

output 3
7346