Popular Vote#7537

Popular Vote

1 secondo
128 megabyte
Molto facile

In an election with more than candidates, it is often the case that the winner (the candidate receiving the most votes) receives less than the majority of the votes. Given the results of an election, can you determine the winner, and whether the winner received more than half of the votes?

Input

The first line indicates the number of test cases t~(t \le 500). The first line of each test case contains a single positive integer indicating the number of candidates in the election. This is followed by lines, with the -th line containing a single nonnegative integer indicating the number of votes candidate received.

There are at least and no more than candidates in each case, and each candidate will not receive more than votes.

Output

For each test case print one line. If the winner receives more than half of the votes, print the phrase "majority winner" followed by the candidate number of the winner. If the winner does not receive more than half of the votes, print the phrase "minority winner" followed by the candidate number of the winner. If a winner cannot be determined because no single candidate has more vote than others, print the phrase "no winner". The candidate numbers in each case are 1, 2, ..., n.

Esempi

Esempio 1

Loading
Loading