CodeEff/ECCO huggingface dataset:
# Original solution
N = int(eval(input()))
a = list(map(int, input().split()))
ans = 0
for i in range(N):
 ans += format(a[i], 'b')[::-1].find('1')
print(ans)

# Optimized solution
int(eval(input()))
print((sum([format(int(a), "b")[::-1].index("1") for a in input().split()])))
# Original solution
N = int(eval(input()))
A = list(map(int, input().split()))

ans = 0
for _ in range(30):
    ans += sum([(a - 1) % 2 for a in A])
    A = [a // 2 for a in A if a % 2 == 0]

print(ans)


# Optimized solution
N = int(eval(input()))
A = list(map(int, input().split()))
ans = 0
for a in A:
    while a % 2 == 0:
        ans += 1
        a //= 2
print(ans)
# Original solution
from functools import reduce
_ = eval(input())
even = reduce(lambda x, y: x * y, list(map(int, input().split())))
i = 0
while even % 2 == 0:
    i = i + 1
    even = even // 2
print(i)

# Optimized solution
_ = eval(input())
even = [int(i) for i in input().split() if int(i) % 2 == 0]
i = 0
while len(even) != 0:
    i = i + len(even)
    even = [i // 2 for i in even if (i // 2) % 2 == 0]
print(i)
# Original solution
n=int(eval(input()))
a=list(map(int, input().split()))
cnt=0

while any(a[i]%2==0 for i in range(n)):
    m=0
    for j in range(n):
        if a[j]%2==0:
            if a[j]>m:
                m=a[j]
                index=j

    for k in range(n):
        a[k]*=3
    
    a[index]=a[index]//6
    cnt+=1

print(cnt)

# Optimized solution
n=int(eval(input()))
a=list(map(int, input().split()))
even_num=[0]*n

for i in range(n):
    cnt=0
    if a[i]%2==0:
        while a[i]%2==0:
            a[i]=a[i]/2
            cnt+=1

    even_num[i]=cnt

ans=sum(even_num)
print(ans)
# Original solution
N = int(eval(input()))
aList = [int(x) for x in input().split()]

# 2で割るor3倍にする
# 全部3倍はダメで、操作後は整数でないとダメ。

en = aList
count = 0
while True:
    cache = []
    for x in en:
        if x % 2 == 0:
            if len(cache) > 0:
                cache.append(int(3*x))
            else:
                cache.append(x // 2)

    if len(cache) > 0:
        count += 1
    else:
        break
    en = cache

print(count)

# Optimized solution
N = int(eval(input()))
aList = [int(x) for x in input().split()]

def calc(x, cache):
    if x % 2 == 0:
        return calc(x//2, cache+1)
    else:
        return cache

count = 0
for x in aList:
    if x % 2 == 0:
        count += calc(x, 0)

print(count)
# Original solution
n = int(eval(input()))
list=list(map(int,input().split()))
count=0
for i in range(n):
    while list[i]%2==0:
        list[i]=list[i]/2
        count+=1
print(count)

# Optimized solution
n = int(eval(input()))
list=list(map(int,input().split()))
count=0
for i in range(n):
    while list[i]%2==0:
        list[i]=list[i]//2
        count+=1
print(count)
# Original solution
from math import log2
n = int(eval(input()))
a = list(map(int, input().split()))
ans = 0

for _a in a:
    if _a%2 == 0:
        cnt =0
        while _a%2 == 0:
            _a //= 2
            cnt += 1
        ans += cnt

print((int(ans)))

# Optimized solution
def f(k):
    cnt = 0
    while k%2 == 0:
        k //= 2
        cnt += 1
        # print(k)
        # print("-----")
    return cnt

n = int(eval(input()))
A = list(map(int, input().split()))
ans = 0

for a in A:
    if a%2 == 0:
        ans += f(a)
print(ans)
# Original solution
n = int(eval(input()))
a = list(map(int,input().split()))
t = 0

while True:
    a.sort(reverse = True)
    x = True
    for i in range(n):
        if a[i] % 2 == 0:
            if x:
                a[i] = a[i] // 2
                x = False
    if x:
        print(t)
        exit(0)
    else:
        t += 1

# Optimized solution
n = int(eval(input()))
a = list(map(int,input().split()))
t = 0

for i in range(n):
    while a[i] % 2 == 0:
        a[i] = a[i] // 2
        t += 1
        
print(t)
# Original solution
def main():
    N = int(eval(input()))
    an = list(map(int, input().split()))
    ans = 0
    for a in an:
        if a % 2 != 0:
            continue
        while True:
            if a % 2 != 0:
                break
            a //= 2
            ans += 1
    print(ans)


main()


# Optimized solution
def main():
    N = int(eval(input()))
    an = list(map(int, input().split()))
    ans = 0
    for a in an:
        while True:
            if a % 2 != 0:
                break
            a //= 2
            ans += 1
    print(ans)


main()
# Original solution
n = int(eval(input()))
a = list(map(int, input().split()))

ans = 0


def d(ai,ans):
    if ai % 2 != 0:
        return ans
    ans += 1
    return d(ai / 2, ans)


for ai in a:
    ans=d(ai,ans)
print(ans)


# Optimized solution
N=int(eval(input()))
A=list(map(int,input().split()))
count=0
for a in A:
    while a%2==0:
        count+=1
        a//=2
print(count)
# Original solution
import operator as o
import functools as f
n,*a=list(map(int,open(0).read().split()))
#print(f.reduce(o.mul,a))
x=f.reduce(o.mul,a)
count=0
while True:
    if x%2==0:
        x=x//2
        count+=1
    else:
        break
print(count)

# Optimized solution
n,*a=list(map(int,open(0).read().split()))
#print(f.reduce(o.mul,a))
a=[s for s in a if s%2==0]
if len(a)==0:
    print((0))
    exit()
count=0

for x in a:
    while True:
        if x%2==0:
            x=x//2
            count+=1
        else:
            break
print(count)
# Original solution
n,*a=list(map(int,open(0).read().split()))
#print(f.reduce(o.mul,a))
a=[s for s in a if s%2==0]
if len(a)==0:
    print((0))
    exit()
count=0

for x in a:
    while True:
        if x%2==0:
            x=x//2
            count+=1
        else:
            break
print(count)

# Optimized solution
n,*a=list(map(int,open(0).read().split()))
def f(x):
    ans=0
    while x%2==0 :
        ans+=1
        x//=2
    return ans
print((sum(map(f,a))))
# Original solution
n=int(eval(input()))

def prime_factors(n):
  i = 2
  factors = []
  while i * i <= n:
    if n % i==0:
      n //= i
      factors.append(i)
    else:
      i += 1
  if n > 1:
    factors.append(n)
  return factors
A=list([prime_factors(x).count(2) if x%2==0 else 0 for x in list(map(int,input().split()))])
print((sum(A)))

# Optimized solution
flag=True
n=int(eval(input()))
A=list(map(int,input().split()))
cnt=0
while flag:
  ls=[]
  tmp=False
  for a in A:
    if a%2==0:
      tmp=True
      cnt+=1
      ls.append(a//2)
  A=ls
  if tmp==False:
    flag=False
print(cnt)
# Original solution
N = eval(input())
a = list(map(int, input().split()))

c = 0

while True:
    gusu = False

    for i, aa in enumerate(a):
        if gusu is False and a[i] % 2 == 0:
            a[i] /= 2
            gusu = True
            continue

    if gusu is False:
        break

    c += 1

print(c)


# Optimized solution
N = eval(input())
a = list(map(int, input().split()))

c = 0

for i, aa in enumerate(a):
    while a[i] % 2 == 0:
        a[i] /= 2
        c += 1

print(c)
# Original solution
# https://abc100.contest.atcoder.jp/tasks/abc100_c


def get_primes_dic(v):
    m = {}
    i = 2

    while i <= v:
        while v % i == 0:
            if i in m:
                m[i] += 1
            else:
                m[i] = 1
            v //= i

        i += 1

    return m


N = int(eval(input()))

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

count = 0

for i in a:
    dic = get_primes_dic(i)
    if 2 in dic:
        count += dic[2]

print(count)



# Optimized solution
# https://abc100.contest.atcoder.jp/tasks/abc100_c


def even_count(v):
    if v % 2 != 0:
        return 0
    else:
        r = 0
        while v % (2 ** 20) == 0:
            r += 20
            v //= (2 ** 20)

        while v % (2 ** 10) == 0:
            r += 10
            v //= (2 ** 10)

        while v % 2 == 0:
            r += 1
            v //= 2

    return r


N = int(eval(input()))

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

count = 0

for i in a:
    count += even_count(i)

print(count)
# Original solution
def factorize2(n):
    """
    nの値を素因数分解し、素因数とその指数をtupleにまとめたリストを返す
    e.g.
    >>> factorize(20)
    [(2, 2), (5, 1)]
    """
    b = 2
    fct = []
    while b * b <= n:
        cnt = 0
        while n % b == 0:
            cnt += 1
            n //= b
        if cnt > 0:
            fct.append((b, cnt))
        b += 1
    if n > 1:
        fct.append((n, 1))
    return fct


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

cnt = 0
for a in A:
    res = factorize2(a)
    if len(res) > 0:
        fct, num = res[0]
        if fct == 2:
            cnt += num
print(cnt)

# Optimized solution
def factorize2(n):
    """
    nの値を素因数分解し、素因数とその指数をtupleにまとめたリストを返す
    e.g.
    >>> factorize(20)
    [(2, 2), (5, 1)]
    """
    b = 2
    fct = []
    while b == 2:
        cnt = 0
        while n % b == 0:
            cnt += 1
            n //= b
        if cnt > 0:
            fct.append((b, cnt))
        b += 1
    if n > 1:
        fct.append((n, 1))
    return fct


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

cnt = 0
for a in A:
    res = factorize2(a)
    if len(res) > 0:
        fct, num = res[0]
        if fct == 2:
            cnt += num
print(cnt)
# Original solution
n = int(eval(input()))
a = list(map(int, input().split()))

s = 0
while True:
    divided = False
    for i in range(n):
        if a[i] % 2 == 0:
            a[i] //= 2
            divided = True
            break
    if divided:
        s += 1
    else:
        break
print(s)


# Optimized solution
n = int(eval(input()))
a = list(map(int, input().split()))

s = 0
for i in range(n):
    while a[i] % 2 == 0:
        a[i] //= 2
        s += 1
print(s)
# Original solution
n = int(eval(input()))
A = list(map(int, input().split()))

ans = 0
waru = 0
cnt = 0

while True:
    for i in range(n):
        if A[i] % 2 == 0:
            if waru == 1:
                A[i] *= 3
            else:
                A[i] //= 2
                waru = 1
        else:
            A[i] *= 3
    if waru == 0:
        print(ans)
        exit()
    else:
        ans += 1
    waru = 0


# Optimized solution
n = int(eval(input()))
A = list(map(int, input().split()))

ans = 0

for a in A:
    while a % 2 == 0:
        a /= 2
        ans += 1

print(ans)
# Original solution
import math

n = int(eval(input()))
a = sorted(list(map(int, input().split())))
aMax, aNum, aMaxSum = 0, 0, 0

for i in range(n):
    aNum, aCnt = a[i], 0
    while aNum % 2 == 0 and aNum / 2 == aNum // 2:
        aCnt += 1
        aNum /= 2
    aMaxSum += aCnt

print(aMaxSum)


# Optimized solution
n = int(eval(input()))
a = list(map(int, input().split()))
aMax, aCnt = 0, 0

for i in range(n):
    while a[i] % 2 == 0:
        aCnt += 1
        a[i] /= 2

print(aCnt)
# Original solution
N = int(eval(input()))
A = list(map(int, input().split()))

def prime_factor(n):
    i = 2
    table = []
    while i * i <= n:
        while n % i == 0:
            n //= i
            table.append(i)
        i += 1
    if n > 1:
        table.append(n)
    return table


ans = 0
for i in range(N):
    ans += prime_factor(A[i]).count(2)

print(ans)

# Optimized solution
N = int(eval(input()))
A = list(map(int, input().split()))


ans = 0
for i in range(N):
    while True:
        if A[i]%2 == 0:
            ans += 1
            A[i] = A[i] // 2
        else:
            break

print(ans)
# Original solution
import functools
N = int(eval(input()))
A = [int(x) for x in input().split()]
P = functools.reduce(lambda a,b: a*b, A)
print((len(bin(P).split('1')[-1])))

# Optimized solution
N = int(eval(input()))
k = 0
for a in map(int, input().split()):
  while a % 2 == 0:
    k += 1
    a //= 2
print(k)
# Original solution
# -*- coding: utf-8 -*-
# 標準入力を取得
N = int(eval(input()))
a = list(map(int, input().split()))

# 求解処理


def get_divisible_count(x: int) -> int:
    divisible_count = 0
    while x % 2 == 0:
        divisible_count += 1
        x /= 2
    return divisible_count


ans = 0
for n in range(N):
    ans += get_divisible_count(a[n])

# 結果出力
print(ans)


# Optimized solution
# -*- coding: utf-8 -*-

def get_input() -> tuple:
    """
    標準入力を取得する.

    Returns:\n
        tuple: 標準入力
    """
    N = int(eval(input()))
    a = list(map(int, input().split()))

    return N, a


def get_divisible_count(x: int) -> int:
    """
    2で何回割ることができるかを返す.

    Args:\n
        x (int): 整数

    Returns:\n
        int: 2で割ることができる回数
    """
    divisible_count = 0
    while x % 2 == 0:
        divisible_count += 1
        x /= 2
    return divisible_count


def main(N: int, a: list) -> tuple:
    """
    メイン処理.

    Args:\n
        N (int): 数列の長さ(1 <= N <= 10000)
        a (list): 数列(1 <= a_i <= 1000000000)

    Returns:\n
        tuple: [description]
    """
    ans = 0
    for n in range(N):
        ans += get_divisible_count(a[n])

    # 結果出力
    print(ans)


if __name__ == "__main__":
    # 標準入力を取得
    N, a = get_input()

    # メイン処理
    main(N, a)
# Original solution
def factorization(n):
    arr = []
    temp = n
    for i in range(2, int(-(-n**0.5//1))+1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr.append([i, cnt])

    if temp != 1:
        arr.append([temp, 1])

    if arr == []:
        arr.append([n, 1])

    return arr


if __name__ == "__main__":
    n = int(eval(input()))
    a = list(map(int, input().split()))

    ans = 0
    for i in range(n):
        tmp = factorization(a[i])
        if tmp[0][0] == 2:
            ans += tmp[0][1]

    print(ans)


# Optimized solution
if __name__ == "__main__":
    n = int(eval(input()))
    a = list(map(int, input().split()))

    ans = 0
    for i in range(n):
        ans += format(a[i], 'b')[::-1].find('1')

    print(ans)
# Original solution
n = int(eval(input()))
lists = list(map(int,input().split()))
count = 0
old = 0
while(True):
    for i in range(n):
        if(lists[i] % 2 ==0):
            lists[i] = lists[i]/2
            count+=1
        else :
            lists[i] = lists[i]*3
    if(count == old):
        break
    old = count
print(count)

# Optimized solution
n = int(eval(input()))
lists = list(map(int,input().split()))
count = 0

for i in range(n):
    if(lists[i] % 2 ==0):
        while(True):
            if(lists[i] % 2 ==0):
                lists[i] = lists[i]/2
                count+=1
            else :
                break
print(count)
# Original solution

N = int(eval(input()))
A = [int(a) for a in input().split()]

def soinsuubunkai(N):
    num_ = N
    list_ = []
    for k in range(2, N+1):
        while True:
            if num_ % k == 0:
                list_.append(k)
                num_ = num_ // k
            else:
                break
    return list_

counter = 0
for a in A:
    tmp = soinsuubunkai(a)
    counter += tmp.count(2)

print(counter)

# Optimized solution

N = int(eval(input()))
A = [int(a) for a in input().split()]

counter = 0
for a in A:
    tmp = a
    while True:
        if tmp == 0:
            break
        elif tmp % 2 == 0:
            counter += 1
            tmp = tmp // 2
        else:
            break


print(counter)
# Original solution
n=int(eval(input()))
A=list(map(int,input().split()))
cnt=0

def f(x):
  tmp=0
  while x%2==0:
    tmp+=1
    x=x/2
  return tmp

for i in range(n):
  cnt+=f(A[i])
 
print(cnt)

# Optimized solution
n=int(eval(input()))
A=list(map(int,input().split()))
cnt=0

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

ans=0
for _ in range(2*(10**4)):
    count=0
    for i in range(n):
        if a[i]%2!=0:
            a[i]*=3
            count+=1
        else:
            a[i]=a[i]//2
            break
    if count==n:
        break
    if count!=n:
        ans+=1
print(ans)

# Optimized solution
n=int(eval(input()))
a=list(map(int,input().split()))

b=[]
for i in range(1,30):
    b.append(2**i)
#print(b)
ans=0
u=len(b)
for i in range(n):
    for j in range(u):
        if a[i]%b[j]==0:
            ans+=1
print(ans)
# Original solution
n = int(eval(input()))
a = list(map(int, input().split()))

res = 0
for i in range(n):
    if a[i] % 2 == 0:
        k = a[i]
        while k % 2 == 0:
            k //= 2
            res += 1

print(res)


# Optimized solution
import sys

sys.setrecursionlimit(10 ** 7)
f_inf = float('inf')
mod = 10 ** 9 + 7


def resolve():
    n = int(eval(input()))
    A = list(map(int, input().split()))

    even = [A[i] for i in range(n) if A[i] % 2 == 0]

    res = 0
    for number in even:
        while number % 2 == 0:
            res += 1
            number //= 2

    print(res)


if __name__ == '__main__':
    resolve()
# Original solution
N=int(eval(input()))
a=list(map(int,input().split()))
sum_val=0
for i in range(N):
  while a[i]%2==0:
    a[i]//=2
    sum_val+=1
print(sum_val)


# Optimized solution
import sys
def input():
  return sys.stdin.readline().rstrip()

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

ans=0
for i in range(N):
  tmp=0
  while a[i]%2==0:
    tmp+=1
    a[i]//=2
  ans+=tmp

print(ans)
# Original solution
#!/usr/bin/env python3
import sys
def input():
    return sys.stdin.readline()[:-1]

def factorization(n):
    arr = []
    temp = n
    for i in range(2, int(-(-n**0.5//1))+1):
        if temp%i==0:
            cnt=0
            while temp%i==0:
                cnt+=1
                temp //= i
            arr.append([i, cnt])
    if temp!=1:
        arr.append([temp, 1])
    if arr==[]:
        arr.append([n, 1])
    return arr

def main():
    N = int(eval(input()))
    a = list(map(int, input().split()))

    ans = 0
    for i in a:
        arr = factorization(i)
        for j in range(len(arr)):
            if arr[j][0] == 2:
                ans += arr[j][1]
    print(ans)


if __name__ == '__main__':
    main()


# Optimized solution
#!/usr/bin/env python3
import sys
def input():
    return sys.stdin.readline()[:-1]

def main():
    N = int(eval(input()))
    a = list(map(int, input().split()))

    ans = 0
    for i in range(N):
        while a[i] % 2 == 0:
            a[i] = a[i] // 2
            ans += 1
    print(ans)

if __name__ == '__main__':
    main()
# Original solution
n = int(eval(input()))
a = list(map(int, input().split()))

cnt = 0

for i in range(n):
    while a[i] % 2 == 0:
        cnt += 1
        a[i] /= 2
print(cnt)

# Optimized solution
n = int(eval(input()))
a = list(map(int, input().split()))
ans = 0
for i in range(len(a)):
    tmp = a[i]
    while tmp % 2 == 0:
        ans += 1
        tmp /= 2
print(ans)
# Original solution
n = int(eval(input()))
a = list(map(int,input().split()))
count = 0

for j in range(n):
  if a[j]%2 == 0:
    arr = []
    temp = a[j]
    for i in range(2, int(-(-a[j]**0.5//1))+1):
        if temp%i==0:
            cnt=0
            while temp%i==0:
                cnt+=1
                temp //= i
            arr.append([i, cnt])

    if temp!=1:
        arr.append([temp, 1])

    if arr==[]:
        arr.append([a[j], 1])
        
    count = count + arr[0][1]
    
print(count)

# Optimized solution
n = int(eval(input()))
a = list(map(int,input().split()))
ans = 0

for i in range(n):
  count = 0
  temp = a[i]
  while (temp%2 == 0):
    temp = temp//2
    count = count + 1
    
  ans = ans + count
  
print(ans)
# Original solution
if __name__ == '__main__':
	eval(input())
	A = list(map(int,input().split()))

	cnt = 0
	EVE = [i for i in A if i % 2 == 0]
	EVE.sort()

	while True:
		if len(EVE) == 0:
			print(cnt)
			break
		else:
			EVE[-1] = EVE[-1] // 2
			if EVE[-1] % 2 == 1:
				EVE.pop(-1)
			else:
				EVE.sort()
			cnt += 1


# Optimized solution
import sys

if __name__ == '__main__':
	eval(input())
	A = list(map(int,sys.stdin.readline().split()))

	cnt = 0
	EVE = [i for i in A if i % 2 == 0]

	for j in EVE:
		while True:
			j = j // 2
			if j % 2 == 1:
				cnt += 1
				break
			cnt += 1

	print(cnt)
# Original solution
N = int(eval(input()))
lis = list(map(int,input().split()))
S = lis[0]
for i in range(2,N+1):
    S *= lis[i-1]
cnt = 0
while S % 2 == 0:
    S = S//2
    cnt += 1
print(cnt)


# Optimized solution
N = int(eval(input()))
lis = list(map(int,input().split()))
cnt = 0
for i in range(N):
    while lis[i] % 2 == 0:
        lis[i] = lis[i]//2
        cnt += 1
print(cnt)
# Original solution
# -*- coding: utf-8 -*-

N = int(input().strip())
a_list = list(map(int, input().rstrip().split()))
#-----

a_list.sort(reverse=True)

Flag=True
cnt=0
while Flag:

    even_flag=False
    for i in range(len(a_list)):
    
        if a_list[i] % 2 == 1:
            #a_list[i] *= 3
            pass
        elif even_flag == False and a_list[i] != 0:
                a_list[i] /= 2
                even_flag = True
        
    if even_flag == True:
        cnt += 1
    else:
        Flag=False
        break

print(cnt)


# Optimized solution
# -*- coding: utf-8 -*-

N = int(input().strip())
a_list = list(map(int, input().rstrip().split()))
#-----

a_even_list=[]
for v in a_list:
    if v%2 == 0 and v != 0:
        a_even_list.append(v)

cnt=0
for v in a_list:
    while v%2 == 0 and v != 0:
        v /= 2
        cnt += 1

print(cnt)
# Original solution
n = int(eval(input()))
a = [int(x) for x in input().split()]

ans = 0
while (1):
   b = [x % 2 for x in a]
   if (0 not in b):
      break

   c = b.index(0)
   a = [int(a[i]/2) if i == c else a[i] for i in range(n)]
   ans += 1

print(ans)


# Optimized solution
n = int(eval(input()))
a = [int(x) for x in input().split()]

ans = 0
while (1):
   b = [x % 2 for x in a]
   ans += b.count(0)
   if (0 not in b):
      break

   a = [int(a[i]/2) if b[i]==0 else a[i] for i in range(n)]

print(ans)
# Original solution
N = int(eval(input()))
array = list(map(int,input().split(" ")))
i = 0
count = 0
while i < N:
    if array[i]%2 == 0:
        array[i] = array[i]/2
        count+=1
    else:
        i+=1
print(count)

# Optimized solution
N=int(eval(input()))
a=list(map(int,input().split()))
count=0
for i in range(N):
  while a[i]%2==0:
    a[i]=int(a[i]/2)
    count+=1
print(count)
# Original solution
n=int(eval(input()))
a=list(map(int,input().split()))
#print(n)
#print(a)
count=0
flag=True
while(flag):
    flag=False
    for i in range(n):
        if(a[i]%2==0):
            #print(i)
            #a=list(map(lambda x:x*3,a))
            a[i]=int(a[i]/2)
            #print(a)
            count+=1
            flag=True
            break
print(count)

# Optimized solution
n=int(eval(input()))
a=list(map(int,input().split()))
#print(n)
#print(a)
count=0
flag=True
while(flag):
    flag=False
    for i in range(n):
        while(a[i]%2==0):
            #print(i)
            #a=list(map(lambda x:x*3,a))
            a[i]=int(a[i]/2)
            #print(a)
            count+=1
            flag=True
            #break
print(count)
#たぶんリスト全部に3かけて該当を６で割ればよさそう
#３倍する必要がない
# Original solution
n = int(eval(input()))
a = [int(i) for i in input().split()]
b = 1
for i in a:
    b *= i
c = 0
while b % 2 == 0:
    b //= 2
    c += 1
print(c)

# Optimized solution
n = int(eval(input()))
a = [int(i) for i in input().split()]
b = 1
c = 0
for i in a:
    b = i
    while b % 2 == 0:
        b //= 2
        c += 1
print(c)
# Original solution
n=int(eval(input()))
a=list(map(int,input().split()))
c=0
b=a[0]
for i in range(1,n):
    b=b*a[i]

for i in range(100000):
    if b%2==0:
        b=b//2
        c+=1
print(c)

# Optimized solution
n=int(eval(input()))
a=list(map(int,input().split()))
c=0
for i in range(0,n):
    while a[i]%2==0:
        a[i]=a[i]//2
        c+=1
print(c)
# Original solution
N = int(eval(input()))
A = [int(i) for i in input().split()]
count = 0
flag = 1
while flag != 0:
    flag = 0
    for i, a in enumerate(A):
        if a % 2 == 0:
            A[i] = a/2
            count += 1
            flag = 1
            break
print(count)


# Optimized solution
N = int(eval(input()))
A = [int(i) for i in input().split()]
count = 0
flag = 1
while flag != 0:
    flag = 0
    for i, a in enumerate(A):
        if a % 2 == 0:
            A[i] = a/2
            count += 1
            flag = 1
print(count)