You are given an array A that consists of N elements.
Assume that a function F(x)=(xmodA1)+(xmodA2)+.....+(xmodAN), for some non-negative integer x. You are required to find the maximum possible value of the function F(x).
Here, XmodY denotes the remainder of the X division by Y.
Input format
Output format
For each test case, print the maximum possible value of F(x) in a new line.
Constraints
1≤T≤10001≤N≤2000001≤Ai≤1000000000
It is guaranteed that the sum of N over T test cases does not exceed 1e6.
For the first testcase, we can take x = 9599. Thus, the maximum possible value of F(x) is 26.
For the second testcase, we can take x = 159. Thus, the maximum possible value of F(x) is 14.