Problem1010--Find the strange number

1010: Find the strange number

[Creator : ]
Time Limit : 2.000 sec  Memory Limit : 128 MiB

Description

Given a list of N positive integers X, each integer except one has even copies, please output the integer which does not have even copies in the list. (N is odd number and guarantee only one integer has odd copies)
( 1 <= N <= 1,000,000  and  1 <= Xi <= 215 )

Input

There are M test cases, ( 0 < M < 100 )
For each case, the first line is integer N and the second line has N integers.
when the case with N = 0, all the input was done

Output

For each case, output one integer which is the number having odd number of copies in the case

Sample Input Copy

5
1 1 3 2 2
3
1 2 1
0

Sample Output Copy

3
2

Source/Category