Under construction

Still being built. Things may change

Three-Legged Race

Interview

Time limit2sMemory limit1024 MB

Summary
Given the team numbers of the first 2N-1 students, find the team of student 2N, which is the only team that appears once.
Level

Easy2 of 10

Topics
Array, Hash map
Solved
No attempts yet

Problem

JOI High School has 2N (= 2 ✕ N) students, numbered from 1 to 2N.

Next month JOI High School holds a sports day. In the Three-Legged Race event, the 2N students race in N teams of 2.

The teams are numbered from 1 to N, and student i (1 ≦ i ≦ 2N) belongs to team Ai.

You made a table of which student belongs to which team, but you have lost track of the team of student 2N.

Given A1, A2, …, A2N-1, find A2N, the team number of student 2N.

Input

Input is given from Standard Input in the following format.

N
A1 A2 … A2N-1

Output

Print A2N, the team number of student 2N.

Constraints

  • 1 ≦ N ≦ 100.
  • 1 ≦ Ai ≦ N (1 ≦ i ≦ 2N - 1).
  • Each x (1 ≦ x ≦ N) appears at most twice in A1, A2, …, A2N-1.
  • All input values are integers.

Examples3

  1. Example 1

    Input
    4
    1 4 2 1 3 4 3
    
    Expected output
    2
    
  2. Example 2

    Input
    10
    5 7 1 9 8 8 2 9 6 5 1 3 6 4 7 3 10 2 4
    
    Expected output
    10
    
  3. Example 3

    Input
    1
    1
    
    Expected output
    1