Given an integer of length , you can perform these types of operations on each digit any number of times :
Select an index such that x_i is even digit and change x_i to \frac{x_i}{2}.
Select an index and change x_i to 2 \cdot x_i (this can only happen if the result is single digit).
How many different integers can we produce? Since the count may be too large , print it modulus .
The first line contains single integer (1 \le t \le 10^4) – the number of test cases.
The first line of each test case contains single integer (1 \le n \le 10^5) – the length of integer .
The second line of each test case contains single integer (1 \le x < 10^{100000}) – the integer .
It's guaranteed that \sum n \le 10^5 overall tests.
For each test case output the count of different integers modulus .
Example 1
In the first test case , the different integers are :
Subtask ( points) : (n=1).
Subtask ( points) : (n \le 4)
Subtask ( points) : (x_1=x_2=....=x_n).
Subtask ( points) : (n \le 10)
Subtask ( points) : (n \le 1000).
Subtask ( points) : No additional constraints