The first line contains the number of test cases T.
The first line of each test case contains the number of schools N (1≤N≤100).
Each of the next N lines contains a school name S (1≤∣S∣≤20) and the amount of alcohol L (0≤L≤10000000) that the school drank over the past year, separated by one space. S is a string of upper and lower case letters with no spaces, and L is an integer.
Within one test case, no two schools have the same amount.