n=int(eval(input()))

d=list(map(int,input().split()))

d.sort()

gn=0

a=d[int(n/2)]-d[int((n/2)-1)]-1



if d[int(n/2)]!=d[int((n/2)-1)]:

  for i in d:

    if i==d[int(n/2)]:

      gn+=1

  if gn>=1:

    a+=1

  print(a)

     

else:

  print((0))
n=int(eval(input()))

d=list(map(int,input().split()))

d.sort()

x=d[int((n-1)/2)]+1

y=d[int(n/2)]



print((y-x+1))
n = int(eval(input()))
d = list(map(int, input().split()))
d.sort()
gn = 0
a = d[int(n / 2)] - d[int((n / 2) - 1)] - 1
if d[int(n / 2)] != d[int((n / 2) - 1)]:
    for i in d:
        if i == d[int(n / 2)]:
            gn += 1
    if gn >= 1:
        a += 1
    print(a)
else:
    print((0))

n = int(eval(input()))
d = list(map(int, input().split()))
d.sort()
x = d[int((n - 1) / 2)] + 1
y = d[int(n / 2)]
print((y - x + 1))

-gn = 0 -a = d[int(n / 2)] - d[int((n / 2) - 1)] - 1 -if d[int(n / 2)] != d[int((n / 2) - 1)]: -    for i in d: -        if i == d[int(n / 2)]: -            gn += 1 -    if gn >= 1: -        a += 1 -    print(a) -else: -    print((0)) +x = d[int((n - 1) / 2)] + 1 +y = d[int(n / 2)] +print((y - x + 1))