#C10973. Find the Unpaired Number

    ID: 40237 Type: Default 1000ms 256MiB

Find the Unpaired Number

Find the Unpaired Number

Given a list of integers where every integer appears an even number of times except for one, your task is to find and output the integer that occurs an odd number of times.

Note: It is guaranteed that exactly one integer in the list will appear an odd number of times.

The solution should read input from standard input and write the result to standard output.

For example, given the input list: [20, 1, 1, 2, 2, 20, 2], the answer is 2 as 2 appears three times (an odd number). Similarly, for input [4, 5, 5, 4, 5], the answer is 5.

inputFormat

The first line contains a single integer n (1 ≤ n ≤ 105), which denotes the number of elements in the array.

The second line contains n space-separated integers. Each integer represents an element in the array.

outputFormat

Output a single integer which is the number that occurs an odd number of times in the list.

## sample
1
10
10