# coding: utf-8

N = int(eval(input()))

p = [ int(eval(input())) for _ in range(N)]

m = max(p)//2

p[p.index(max(p))] = 0

print((sum(p)+m))
# coding: utf-8

p = [ int(eval(input())) for _ in range(int(eval(input())))]

print((sum(p)-max(p)//2))
# coding: utf-8
N = int(eval(input()))
p = [int(eval(input())) for _ in range(N)]
m = max(p) // 2
p[p.index(max(p))] = 0
print((sum(p) + m))

# coding: utf-8
p = [int(eval(input())) for _ in range(int(eval(input())))]
print((sum(p) - max(p) // 2))

-N = int(eval(input())) -p = [int(eval(input())) for _ in range(N)] -m = max(p) // 2 -p[p.index(max(p))] = 0 -print((sum(p) + m)) +p = [int(eval(input())) for _ in range(int(eval(input())))] +print((sum(p) - max(p) // 2))