bad-odd-times
Source: hackerearth
Difficulty: UNKNOWN_DIFFICULTY

Once upon a times , there lived King Nihal who hated odd counting . He has received various gifts from different kings of other kingdoms on his birthday. 
There is one enemy king , and to make our king angry he will send odd number of gifts . As a sincere minister , its your task to find the enemy kingdom.

Input

T- number of test cases

N- number of  gifts he received

N inputs each corresponding to the Kingdom  from which the gift has come.

The gift number represents the Id of kingdom from which he received the gift

Output

Id of enemy kingdom

constraints
0<T<11
0<N ≤ 10^6
0<id<10^4

Eg.

2

7

1 1 2 2 2 2 3

5

4 4 4 7 7

Output

3

4

Explanation

In the second test case he got 5 gifts from 2 kingdoms( id 4 and id 7 ), now kingdom 4 sends him odd number of
gifts (3) so we find out that kingdom id 4 is his enemy.

SAMPLE INPUT
2

7

1 1 2 2 2 2 3

5

4 4 4 7 7

SAMPLE OUTPUT
3
4


for _ in range(eval(input())):
	x=eval(input())
	danger={}
	ids=list(map(int,input().split()))
	for i in ids:
		if i not in danger:
			danger[i]=1
		else:
			danger[i]+=1
	for khatra in danger:
		if danger[khatra]%2:
			print(khatra)


def process(l):
	dc={}
	for i in range(len(l)):
		if l[i] not in dc:
			dc[l[i]]=1
		else:
			dc[l[i]]+=1
	lk=list(dc.keys())
	for i in range(0,len(lk)):
		if dc[lk[i]]%2!=0:
			print(lk[i])
			break
tc=int(eval(input()))
while tc>0:
	n=int(eval(input()))
	l=list(map(int,input().split()))
	process(l)
	tc=tc-1


for _ in range(eval(input())):
	memo={}
	x=input()
	ids=list(map(int,input().split()))
	for i in ids:
		if i not in memo:
			memo[i]=1
		else:
			memo[i]+=1
	for memos in memo:
		if memo[memos]%2:
			print(memos)