Carlinhos, the best pizza maker in the solar system, discovered a new technique for cooking his pizzas: baking them on the Sun! The news of Carlinhos' new pizzas quickly spread throughout the galaxy. So, Rachel and Matheuzin, space pizza sommeliers, decided to travel to the Sun to try the novelty.
Rachel and Matheuzin went to Carlinhos' pizzeria with a group of $$$2n$$$ friends, each of whom has a favorite pizza flavor. Since they spent a lot of money on the trip, they decided to save on pizzas. Therefore, they will order $$$n$$$ pizzas, each divided into two halves of different flavors. The price of a pizza whose halves have values $$$p$$$ and $$$q$$$ is $$$\max(p,q)$$$.
Help Rachel and Matheuzin find a way to pay as little as possible for the pizzas.
The first line of input has a single integer $$$n$$$ ($$$1 \leq n \leq 10^5$$$) — the number of pizzas that will be ordered.
The second line of input has $$$2n$$$ integers $$$p_1, p_2, \dots, p_{2n}$$$ ($$$1 \leq p_i \leq 10^4$$$), where $$$p_i$$$ is the price of the flavor which the $$$i$$$-th wants to eat.
Print a single integer, the least possible price of the $$$n$$$ pizzas with the required flavors.
23 5 3 4
8