import Control.Monad
import Data.List

main = do
  n <- readLn
  [as, bs] <- transpose . map (map read . words) <$> replicateM n getLine
  print $ solve n (sort as) (sort bs)

solve :: Int -> [Int] -> [Int] -> Int
solve n as bs
  | odd n = bs !! div n 2 - as !! div n 2 + 1
  | otherwise = bs !! div n 2 + bs !! div (n - 1) 2 - as !! div n 2 - as !! div (n - 1) 2 + 1