N = int(eval(input()))

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



e = 0

for a in A:

    while a&1 == 0:

        e += 1

        a >>= 1

print(e)
N = int(eval(input()))

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



e = 0

for a in A:

    l = 0

    over = a.bit_length()

    while over - l > 1:

        m = (l+over) // 2

        if a % (1<<m) == 0: l = m

        else: over = m

    e += l

print(e)
N = int(eval(input()))
A = list(map(int, input().split()))
e = 0
for a in A:
    while a & 1 == 0:
        e += 1
        a >>= 1
print(e)

N = int(eval(input()))
A = list(map(int, input().split()))
e = 0
for a in A:
    l = 0
    over = a.bit_length()
    while over - l > 1:
        m = (l + over) // 2
        if a % (1 << m) == 0:
            l = m
        else:
            over = m
    e += l
print(e)

-    while a & 1 == 0: -        e += 1 -        a >>= 1 +    l = 0 +    over = a.bit_length() +    while over - l > 1: +        m = (l + over) // 2 +        if a % (1 << m) == 0: +            l = m +        else: +            over = m +    e += l