Jaś and Staś play a card game called the Byteotian War. At the start of the game each player receives a deck of n cards. Every card has a single integer written on it.
The game is played in turns. On each turn every player takes the top two cards of their own deck and chooses one to discard and the other to hand to the opponent. On every turn exactly one card is discarded and exactly one is handed over. The opponent places the received card at the bottom of their own deck.
The game ends once both players are left with a single card. If the number on Jaś's card is j and the number on Staś's card is s, then Jaś earns j−s points and Staś earns s−j points.
Assume both players play optimally, each maximizing their own score computed by the rule above. How many points does Jaś earn?
The first line contains a single integer n (1≤n≤106), the number of cards each player receives. The second line contains n integers ai (1≤ai≤106) describing Jaś's deck from the top card down. The third line describes Staś's deck in the same format.
Print a single integer, the number of points Jaś earns when both players play optimally.