12068 - CS_2018_MID1-2   

Description

Given a sequence of n integers, sort the integers in increasing order.

Find and print the largest difference between two neighboring integers in the sorted sequence.

 

For example, if the original sequence is 7 -3 2 5 12 8, the output should be 5.

Because the sorted sequence is -3, 2, 5, 7, 8, 12 and the largest difference is between -3 and 2, which is 5.

Input

The first line is an integer T (T <= 20) denoting the number of test cases.

Each test case consists of two lines. The first line contains a number n (n <= 104) indicating the length of the sequence, and the second line contains the sequence of n integers V1, V2, ..., Vn. (-2^31 < Vi < 2^31 - 1 for 1 <= i <= n )

Output

The output of each test case contains one integer ended by '\n'.

Sample Input  Download

Sample Output  Download

Tags




Discuss