eval(input());l=sorted(map(int,input().split()));print((sum(l[-1::-2])-sum(l[-2::-2])))


eval(input());c=0

for a in sorted(map(int,input().split())):c=a-c

print(c)
eval(input())
l = sorted(map(int, input().split()))
print((sum(l[-1::-2]) - sum(l[-2::-2])))

eval(input())
c = 0
for a in sorted(map(int, input().split())):
    c = a - c
print(c)

-l = sorted(map(int, input().split())) -print((sum(l[-1::-2]) - sum(l[-2::-2]))) +c = 0 +for a in sorted(map(int, input().split())): +    c = a - c +print(c)