let n = read_int ()

let rec read_ints accu = function
  | 0 -> List.rev accu
  | k -> read_ints ((Scanf.scanf " %d" (fun x -> x)) :: accu) (k-1)

let a = Array.of_list (read_ints [] (2*n-1))

let check x =
  let rec find next p i =
    if p i && (a.(next i) >= x) != (a.(i) >= x) then find next p (next i)
    else i
  in
  let i = find (fun x -> x-1) (fun x -> x > 0) (n-1) in
  let j = find (fun x -> x+1) (fun x -> x < 2*n-2) (n-1) in
  if n-1-i < j-n+1 then a.(i)>=x else a.(j)>=x

let rec bsearch l r = if r = l+1 then l else let m = (l+r)/2 in if check m then bsearch m r else bsearch l m

let () = print_int (bsearch 1 (2*n))