Goodies

0

0 votes
Problem

HackerEarth has sponsored a lot of goodies for the 'Google Week' to be held at Sir MVIT. The goodies are in the form of boxes. Each box has a surprise value associated with it.

To carry the boxes from his hostel to the venue, Karan puts the box with the smaller surprise value inside the box with larger surprise value. A box can only contain a single box inside it. Basically, if surprise_value[i]<surprise_value[j], then j can accommodate i inside it.

Input

The first line contains the number of test cases T. Every test case contains a number N, denoting the number of total goodie boxes. This is followed by N lines, containing the surprise value of each box, X.

Output

You've to output the minimum number of boxes, optimally putting one inside each other.

Constraints

1 <= T <= 10

1 <= N <= 100000

1 <= X <= 10000

Time Limit: 5
Memory Limit: 256
Source Limit:
Explanation

Explanation Test Case # 1:

There are three boxes of value 1 , 2 and 3 Box of value 1 can fit inside box of value 2 and now box of value 2 which contains box of value 1 can fit inside box of value 3. So finally there will be only one box.

Test Case # 2:

There are four boxes of same value 2 so we can't put boxes inside of any other box of same value. So the answer will be 4.

Test Case # 3:

There are three boxes of value 11,111,1111 . Box of value 11 can fit inside box of value 111 and box of value 111 which contains box of value 11 can fit inside box of value 1111 . At final there will be only one box so answer is 1.

Editor Image

?