import Data.List main = do n <- readLn as <- sort . map read . words <$> getLine print $ (as!!(div n 2) + as!!(div (n-1) 2)) / 2