N = int(eval(input()))

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

result = 0

for i in a:

	while True:

		if i%2!=0:

			break

		else:

			i/=2

			result += 1

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

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

p = 0

for i in a:

    cnt = 0

    while i % 2 == 0:

        cnt += 1

        i //= 2

    p += cnt

print(p)

N = int(eval(input()))
a = list(map(int, input().split()))
result = 0
for i in a:
    while True:
        if i % 2 != 0:
            break
        else:
            i /= 2
            result += 1
print(result)

n = int(eval(input()))
a = list(map(int, input().split()))
p = 0
for i in a:
    cnt = 0
    while i % 2 == 0:
        cnt += 1
        i //= 2
    p += cnt
print(p)

-N = int(eval(input())) +n = int(eval(input())) -result = 0 +p = 0 -    while True: -        if i % 2 != 0: -            break -        else: -            i /= 2 -            result += 1 -print(result) +    cnt = 0 +    while i % 2 == 0: +        cnt += 1 +        i //= 2 +    p += cnt +print(p)