import Data.List
import Data.Char
import Data.Maybe
import qualified Data.ByteString.Char8 as BS8

main :: IO ()
main = do
    n <- fst . fromJust . BS8.readInteger <$> BS8.getLine
    vi <- unfoldr (BS8.readInteger . BS8.dropWhile isSpace) <$> BS8.getLine
    let v = reverse $ sort [toRational x | x <- vi]

    print $ fromRational $ foldr (\x y -> ((x + y) / 2)) (last v) (init v)
