Problem:
 Score: 300 points    Problem Statement  As AtCoder Beginner Contest 100 is taking place, the office of AtCoder, Inc. is decorated with a sequence of length N , a = { a_1, a_2, a_3, ..., a_N }. Snuke, an employee, would like to play with this sequence.  Specifically, he would like to repeat the following operation as many times as possible:  For every i satisfying 1 \leq i \leq N , perform one of the following: "divide a_i by 2 " and "multiply a_i by 3 ".  
Here, choosing "multiply a_i by 3 " for every i is not allowed, and the value of a_i after the operation must be an integer.  At most how many operations can be performed?      Constraints   N is an integer between 1 and 10 \ 000 (inclusive).  a_i is an integer between 1 and 1 \ 000 \ 000 \ 000 (inclusive).         Input  Input is given from Standard Input in the following format:  N  a_1  a_2  a_3  ...  a_N       Output  Print the maximum number of operations that Snuke can perform.        Sample Input 1 3
5 2 4      Sample Output 1 3  The sequence is initially {5, 2, 4} . Three operations can be performed as follows:   First, multiply a_1 by 3 , multiply a_2 by 3 and divide a_3 by 2 . The sequence is now {15, 6, 2} .  Next, multiply a_1 by 3 , divide a_2 by 2 and multiply a_3 by 3 . The sequence is now {45, 3, 6} .  Finally, multiply a_1 by 3 , multiply a_2 by 3 and divide a_3 by 2 . The sequence is now {135, 9, 3} .        Sample Input 2 4
631 577 243 199      Sample Output 2 0  No operation can be performed since all the elements are odd. Thus, the answer is 0 .       Sample Input 3 10
2184 2126 1721 1800 1024 2528 3360 1945 1280 1776      Sample Output 3 39

Solution (Python):

def judge(a):
    ans=0
    while a%2==0:
        a/=2
        ans+=1
    return ans

if __name__ == '__main__':
    N=int(input())
    A=list(map(int,input().split()))
    count=0
    for a in A:
        count+=judge(a)

    print(count)

Solution (Python):
N=int(input())
A=[int(i) for i in input().split()]

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

Solution (Python):
from math import log2

N = int(input())
L = list(map(int, input().split()))

res = 0

for num in L:
    l = num
    while (l % 2 == 0):
        res += 1
        l = l //  2
    
print(res)

Solution (Python):
import sys
import math

sys.setrecursionlimit(10**6)
if sys.platform in (['ios','darwin','win32']):
	sys.stdin=open('Untitled.txt')
input = sys.stdin.readline
def INT(): return int(input())
def MAP(): return [int(s) for s in input().split()]

N = INT()
A = MAP()

def devide(n):
	ret = 0
	while n%2 == 0:
		ret += 1
		n //= 2
	return ret

B = [devide(a) for a in A]


print(sum(B))

Solution (Python):
N = int(input())
a = list(map(int,input().split()))
counter = 0
flag = 1

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

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
n = 0
for i in range(len(A)):
    while int(A[i])% 2 == 0:
        n +=1
        A[i] = A[i]/2
print(n)

Solution (Python):
N = input()
N = int(N)
a = input()
a = a.split()
L = len(a)
b = []
ans = 0
flag = 1
for i in range(L):
    b.append(int(a[i]))
while(flag):
    flag = 0
    for i in range(N):
        if(b[i] % 2 == 0):
            ans = ans + 1
            b[i] = b[i] / 2
            flag = 1
print(ans)

Solution (Python):
def main(n: int, a: list):
    ans = 0

    for a in a:
        while True:
            a /= 2

            if a.is_integer():
                ans += 1
            else:
                break

    print(ans)


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

    main(n, a)

Solution (Python):
N=int(input())
a=list(map(int, input().split()))

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

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
ans=0
for i in range(n):
  while a[i]%2==0:
    a[i]/=2
    ans+=1
print(ans)

Solution (Python):
N = int(input())
a = list(map(int, input().split()))
ans = 0
for i in a:
    ans += format(i, 'b')[::-1].find('1')
print(ans)

Solution (Python):
N = int(input())

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

cnt = 0

for num in seq:
    while num % 2 == 0:
        cnt += 1
        num /= 2

print(cnt)

Solution (Python):
N=int(input())
a=[int(a) for a in input().split()]
rec=[False]*N
cnt=0
for b in range(35,0,-1):
    for i in range(N):
        if a[i]%(2**b)==0 and rec[i]==False:
            cnt+=b
            rec[i]=True
print(cnt)

Solution (Python):

import sys

N = int(sys.stdin.readline())
A = list(map(int, sys.stdin.readline().split()))


def calc(a):
    cnt =0
    while True:
        if a %2==0:
            cnt+=1
            a = a//2
        else:
            return cnt
            break

ans =0
for a in A:
    ans +=calc(a)

print(ans)

Solution (Python):

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


import numpy as np
a = np.array(a)
a = a[a % 2 == 0]

def square_power(n, p):
    if n % 2**p == 0:
        return True
    else:
        return False

def is_possible(n):
    left = -1
    right = 30
    while left + 1 < right:
        mid = (left+right)//2
        if square_power(n, mid):
            left = mid
        else:
            right = mid
    return left

answer = 0
for b in a:
    answer += is_possible(b)

print(answer)

Solution (Python):
n = int(input())
ali = list(map(int, input().split()))
total = 0
for a in ali:
    while a%2==0:
        a = (a//2)
        total += 1
print(total)

Solution (Python):
n=int(input())
alis=list(map(int,input().split()))
counter=0
for i in range(1,31)[::-1]:
	for j in range(n):
		if alis[j]%(2**i)==0:
			alis[j]=alis[j]//(2**i)
			counter+=i
print(counter)

Solution (Python):
import sys
n = int(input())
a_ls = [int(i) for i in sys.stdin.readline().split()]
cnt = 0
for a in a_ls:
    while a % 2 == 0:
        a //= 2
        cnt += 1
print(cnt)

Solution (Python):
num = int(input())
flag_list = [int(i) for i in input().split()]

ans = 0

for val in flag_list:
    while val % 2 == 0:
        val //= 2
        ans += 1

print(ans)

Solution (Python):
num = int(input())
flag_list = [int(i) for i in input().split()]


ans = 0
cont_game = True

for val in flag_list:
    while val % 2 == 0:
        val //= 2
        ans += 1

print(ans)

Solution (Python):



n=int(input())
a=[int(i) for i in input().split()]

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

print(k)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

ans = 0

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

print(ans)

Solution (Python):
N = int(input())
a = list(map(int, input().split()))

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

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
cnt = 0
for i in range(n):
    while a[i]%2 == 0:
        a[i] = a[i]//2
        cnt += 1
print(cnt)

Solution (Python):
N=int(input())
a=list(map(int,input().split()))
ans=0
for i in a:
  for j in range(1,32):
    if i % (2**j)==0:
      ans += 1
    else:
      break
print(ans)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
count = 0
for i in A:
    while i % 2 == 0:
        i /= 2
        count += 1

print(count)

Solution (Python):
n = int(input())
L = list(map(int, input().split()))
E = []
for i in range(n):
  if L[i]%2 != 1:
    E.append(L[i])

out = 0    
for i in range(len(E)):
  out += bin(E[i])[::-1].find('1')
  
print(out)

Solution (Python):
N=int(input())
A= list(map(int,input().split() ))
ans=0
for a in A:
  while a%2==0:
    a/=2
    ans+=1
print(ans)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(n):
    while a[i] % 2 == 0:
        a[i] //= 2
        cnt += 1
print(cnt)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(n):
    if a[i] % 2 == 0:
        while a[i] % 2 == 0:
            a[i] //= 2
            cnt += 1
print(cnt)

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

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
ans = 0
for a in A:
    cnt = 0
    for i in range(1,a + 1):
        if a % 2**i == 0:
            cnt += 1
        else:
            break
    ans += cnt
print(ans)

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

import numpy as np

N = int(readline())
A = np.array(read().split(),np.int32)

answer = 0
for _ in range(32):
    A = A[A%2 == 0]
    answer += len(A)
    A >>= 1
print(answer)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

cnt = 0
for i in a:
	if i % 2 == 0:
		while i % 2 == 0:
			i /= 2
			cnt += 1
print (int(cnt))

Solution (Python):
def examC():
    N= I()
    A = LI()
    cur = 0
    for i in A:
        while(True):
            if i % 2 == 0:
                i //= 2
                cur += 1
            else:
                break
    print(cur)



import sys,copy,bisect,itertools,heapq,math
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict,deque
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))
def LSI(): return list(map(str,sys.stdin.readline().split()))
def LS(): return sys.stdin.readline().split()
def SI(): return sys.stdin.readline().strip()
mod = 10**9 + 7
inf = float('inf')

examC()

Solution (Python):
import numpy as np

N=int(input())
A=np.asarray(list(map(int,input().split(" "))))
csum=0 


while True:
    cond=(A%2==0) 
    c=(cond).sum() 
    csum+=c 

    if c==0: 
        break

    A=A[cond]//2 

print(csum)

Solution (Python):
N = int(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] /= 2
        else:
            break
print(ans)

Solution (Python):
def two_div(n):
    count=0
    while n%2!=1:
        n=n/2
        count+=1
    return count

N=int(input())
L=list(map(int,input().split()))
L_div=[two_div(i) for i in L]
print(sum(L_div))

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

count = 0

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

print(count)

Solution (Python):
n = int(input())
list_a = list(map(int, input().split()))
count = 0
for one_a in list_a:
  temp = one_a
  while temp % 2 == 0:
    count += 1
    temp //= 2
print(count)

Solution (Python):
n = int(input())
A = list(map(int,input().split()))
cnt = 0
for i in range(n):
    if A[i]%2==0:
        while A[i]%2==0:
            A[i]=A[i]//2+A[i]%2
            cnt += 1
print(cnt)

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
ans=0
for x in a:
  while x%2==0:
    x/=2
    ans+=1
print(ans)

Solution (Python):
N = int(input())
*A,= map(int, input().split())


ans = 0
for i in A :
  while i%2 == 0 :
    i = i/2
    ans +=1
print(ans)

Solution (Python):

N = int(input())
A = list(map(int, input().split()))
l = [2**i for i in range(29, -1, -1)]
ans = 0
for i in range(N):
    flag = False
    for j in range(len(l)):
        if A[i] % l[j] == 0 and flag==False:
            ans += 29 - j
            flag = True
print(ans)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

ans = 0

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

print(ans)

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

Solution (Python):
import math
N=input()
a=list(map(int,input().split()))
ans=0
for i in a:
  ans+=len(bin(i))-bin(i).rfind("1")-1

print(ans)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
cnt = 0
for a in A:
    while a % 2 == 0:
        a /= 2
        cnt += 1
print(cnt)

Solution (Python):
import sys

input = sys.stdin.readline

def main():
    N = int(input())
    
    ans = 0
    
    for a in list(map(int, input().split())):
        while not a % 2:
            ans += 1
            a //= 2
    print(ans)
    
if __name__ == '__main__':
    main()

Solution (Python):
import sys
input = sys.stdin.readline
N = int(input())
A = list(map(int, input().split()))
cnt = 0
for a in A:
    while a % 2 == 0:
        a /= 2
        cnt += 1
print(cnt)

Solution (Python):
n = int(input())
al = list(map(int,input().split()))

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

Solution (Python):
n = int(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)

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

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

def check_two(num):
    count = 0
    while num % 2 == 0:
        num /= 2
        count += 1
    return count

total_count = 0
for i in range(n):
    total_count += check_two(a[i])

print(total_count)

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

Solution (Python):
N=int(input())
A=list(map(int,input().split()))

def divide(a):
    count=0
    while a%2 == 0: 
        a=a//2
        count+=1
    else:
        return count

Ans=0
for i in A:
    Ans+=divide(i)
print(Ans)

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

Solution (Python):
n = int(input())
A = list(map(int, input().split()))
c = 0
for i in A:
  while i%2 == 0:
    i //= 2
    c += 1
print(c)

Solution (Python):
N=int(input())
A=list(map(int,input().split()))


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

Solution (Python):
from collections import Counter,defaultdict,deque
from heapq import heappop,heappush,heapify
import sys,bisect,math,itertools
sys.setrecursionlimit(10**8)
mod = 10**9+7
mod2 = 998244353
INF = float('inf')
def inp(): return int(sys.stdin.readline())
def inpl(): return list(map(int, sys.stdin.readline().split()))
def inpln(n): return list(int(sys.stdin.readline()) for i in range(n))

def f(x):
    cnt = 0
    while True:
        if x%2:
            return cnt
        else:
            x //= 2
            cnt += 1
n = inp()
a = inpl()
res = 0
for i in a:
    res += f(i)
print(res)

Solution (Python):

import sys, math
input = lambda: sys.stdin.buffer.readline().rstrip().decode('utf-8')
sys.setrecursionlimit(10**8)
inf = float('inf')
ans=count=0

def div2(n):
    count=0
    while n%2==0:
        n=n//2
        count+=1
    return count
        

n=int(input())
a=list(map(int,input().split()))
for ai in a:
    count+=div2(ai)
print(count)

Solution (Python):

import sys, math
input = lambda: sys.stdin.buffer.readline().rstrip().decode('utf-8')
sys.setrecursionlimit(10**8)
inf = float('inf')
ans=count=0

def div2(n):
    count=0
    while n%2==0:
        n=n//2
        count+=1
    return count
        

n=int(input())
a=list(map(int,input().split()))
for ai in a:
    count+=div2(ai)
print(count)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))



cnt = 0
for num in a:
  while num%2 == 0:
    num /= 2
    cnt += 1
print(cnt)

Solution (Python):
N = int(input())
A = [int(x) for x in input().split()]
ans = 0
for a in A:
    while a % 2 == 0:
        ans += 1
        a /= 2
print(ans)

Solution (Python):
from sys import stdin
import fractions

n = int(stdin.readline().rstrip())
li = list(map(int,stdin.readline().rstrip().split()))


def prime_factorize(n):
    a = []
    while n % 2 == 0:
        a.append(2)
        n //= 2
    f = 3
    while f * f <= n:
        if n % f == 0:
            a.append(f)
            n //= f
        else:
            f += 2
    if n != 1:
        a.append(n)
    return a

point = 0

for i in li:
    lin = prime_factorize(i)
    point += lin.count(2)

print(point)

Solution (Python):
n=int(input())
ans=0
cnt=0
a=list(map(int,input().split()))
for i in range(n):
    for j in range(100):
        if a[i]%2==0:
            a[i]=a[i]//2
            cnt+=1
        else:
            ans+=cnt
            cnt=0
print(ans)

Solution (Python):
N = int(input())
a = list(map(int,input().rstrip().split()))

ans = 0
i = 0
while i < N:
    if a[i]%2 == 0:
        ans += 1
        a[i] /= 2
        i -= 1
    i += 1

print(ans)

Solution (Python):
N = int(input())
a = list(map(int,input().split()))
tmp = []
for i in range(N):
    if a[i]%2 == 0:
        tmp.append(a[i])
if tmp == []:
    print(0)
else:
    ans = 0
    for i in range(len(tmp)):
        num = tmp[i]
        count = 0
        while num%2 == 0:
            num = num/2
            count += 1
        ans += count
    print(ans)

Solution (Python):
N = int(input())
d = {}

def f(x):
  if x in d:
    return d[x]
  if x % 2 == 0:
    d[x] = 1 + f(x / 2)
    return d[x]
  else:
    d[x] = 0
    return d[x]

A = list(map(lambda x: f(x), [int(x) for x in input().split()]))
print(sum(A))

Solution (Python):
n=int(input())
A=list(map(int,input().split()))
r=0
for i in range(n):
   while A[i]%2==0:
       A[i]//=2
       r+=1
print(r)

Solution (Python):
N = int(input())
a = list(map(int, input().split()))

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

Solution (Python):
n = int(input())
A = list(map(int, input().split()))

count = 0

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

print(count)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
i = 0
sousa = 0
while i <= n-1:
  j = 0
  while j == 0:
    if a[i]%2 == 0:
      a[i] = a[i]/2
      sousa += 1
      j = 0
    else:
      j = 1
  i += 1
print(sousa)

Solution (Python):
n = int(input())
a_list = list(map(int, input().split()))
def count_2(num):
    count = 0
    while num%2 == 0:
        num /= 2
        count += 1
    return count
ans = 0
for i in range(n):
    ans += count_2(a_list[i])
print(ans)

Solution (Python):

import sys
input = lambda: sys.stdin.buffer.readline().rstrip().decode('utf-8')
sys.setrecursionlimit(10**8)
inf = float('inf')
mod = 10**9+7

def f(num):
    global count
    while num%2==0:
        num=num//2
        count+=1


n=int(input())
A=list(map(int,input().split()))
count=0
for a in A:
    f(a)
print(count)

Solution (Python):
n=int(input())
a=[int(x) for x in input().split()]

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

print(c)

Solution (Python):
def d2(n):
    cnt=0
    while n%2==0:
        n=n//2
        cnt+=1
    return cnt

n=int(input())
A=list(map(int,input().split()))
ans=0
for i in range(n):
    ans += d2(A[i])
print(ans)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
cnt = 0
for a in A:
    while True:
        if a % 2 == 0:
            a /= 2
            cnt += 1
        else:
            break
print(cnt)

Solution (Python):



import sys

import math











def main():
    n, *a = (int(x) for x in sys.stdin.read().split())

    total_count = 0
    atmost = math.floor(math.log(10 ** 9, 2))
    for i in range(n):
        current = a[i]
        count = 0
        for _ in range(atmost + 1):
            if current % 2 == 0:
                current //= 2
                count += 1
            else:
                break
        total_count += count
    
    print(total_count)

if __name__ == "__main__":
    
    main()

Solution (Python):



import sys

import math











def main():
    n, *a = (int(x) for x in sys.stdin.read().split())

    total_count = 0
    for i in range(n):
        current = a[i]
        count = 0
        for _ in range(math.floor(math.log(10 ** 9, 2)) + 1):
            if current % 2 == 0:
                current //= 2
                count += 1
            else:
                break
        total_count += count
    
    print(total_count)

if __name__ == "__main__":
    
    main()

Solution (Python):
N = int(input())
A = list(map(int,input().split()))

con = 0

for i in range(0,N):
  while A[i] % 2 == 0:
    A[i] = A[i] // 2
    con += 1

print(con)

Solution (Python):
import math
point=0
N=int(input())
L=list(map(int,input().split()))
for j in L:
  s=0
  while j%2==0:
    s+=1
    j//=2
  point+=s
print(point)

Solution (Python):
N = int(input())
a = list(map(int, input().split()))
ans = 0
for i in range(N):
  while a[i]%2==0:
    ans += 1
    a[i] /= 2
print(ans)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

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

Solution (Python):

import math

def main():
    N = int(input())
    a_list = [int(s) for s in input().split()]
    sousa_count = 0
    for a in a_list:
        sousa_count += count_devide_2(a)
    print(sousa_count)

def count_devide_2(num):
    count = 0
    while True:
        if num%2 == 0:
            num = math.floor(num/2)
            count += 1
        else:
            return count

if __name__ == "__main__":
    main()

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(len(a)):
    while a[i] % 2 == 0:
        a[i] = a[i] // 2
        cnt += 1
print(cnt)

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
ans = 0
for a in A:
    while a%2 == 0:
        a = a//2
        ans += 1
print(ans)

Solution (Python):
from collections import deque

n = int(input())
a = deque(map(int, input().split()))

cnt = 0
while len(a)>0:
    x = a.pop()
    if x%2 == 0:
        a.append(x//2)
        cnt += 1
print(cnt)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

cnt = 0
while len(a)>0:
    x = a.pop()
    if x%2 == 0:
        a.append(x//2)
        cnt += 1
print(cnt)

Solution (Python):
N=int(input())
A=list(map(int,input().split()))
n=0
for a in A:
  while a%2==0:
    n+=1
    a/=2
print(n)

Solution (Python):
N = int(input())
A = list(map(lambda x: int(x), input().split(' ')))

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

print(ans)

Solution (Python):
N = int(input())
a = list(map(int, input().split()))
ain2 = [0]*N
for i in range(N):
    k = a[i]
    count = 0
    while(k % 2 == 0):
        k = k / 2
        count += 1
    ain2[i] = count
print(sum(ain2))

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
count=0
for i in range(n):
  num=l[i]
  while num%2==0:
    count+=1
    num=num//2
print(count)

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
s = 0
for n in range(N):
  a = A[n]
  while a%2 == 0:
    a = a//2
    s = s+1
print(s)

Solution (Python):
N=int(input())
A=list(map(int,input().split()))
count=0
for i in A:
    while i%2==0:
        i=round(i/2)
        count+=1
print(count)

Solution (Python):
N=int(input())
A=[int(x) for x in input().split()]
B=[]
for i in range(N):
    B +=[bin(A[i])[::-1].find('1')]
print(sum(B))

Solution (Python):
def f(n):
  c = 0
  while n % 2 == 0:
    c += 1
    n = n // 2
  return c
 
n = int(input())
a = list(map(int, input().split()))
print(sum((f(ai) for ai in a if ai % 2 == 0)))

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
total = 0
for i in range(n):
    while a[i]%2==0:
        a[i] = a[i]//2
        total += 1
    else:
        continue
print(total)

Solution (Python):
n=int(input())
l=[int(i) for i in input().split()]
cnt=0 
for i in l:
    while i:
        if i%2:
            break 
        cnt+=1 
        i>>=1 
print(cnt)

Solution (Python):
import math

n=int(input())
a_list=list(map(int,input().split()))

count=0
for a in a_list:
    tmp=a
    while (tmp%2==0):
        count+=1
        tmp=tmp//2

print(count)

Solution (Python):
def input():
    import sys
    return sys.stdin.readline().rstrip()


def main():
    import math
    import collections
    import itertools

    n = int(input())
    as_ = list(map(int, input().split()))
    num_div = 0
    for a in as_:
        i = 0
        while True:
            if a & (1 << i) == 0:
                num_div += 1
                i += 1
            else:
                break
    print(num_div)




if __name__ == '__main__':
    main()

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
count=0
for i in range(n):
    num=a[i]
    while num%2==0:
        num//=2
        count+=1
print(count)

Solution (Python):
n = int(input())
a = [int(x) for x in input().split()]
ans = 0
for i in a:
    while i % 2 == 0:
        ans += 1
        i /= 2
print(ans)

Solution (Python):
def cnt(n):
    res = 0
    while True:
        n = n / 2
        if n.is_integer():
            res += 1
        else:
            return res


ans = 0
_ = input()
for a_str in input().split():
    a = int(a_str)
    if a % 2 == 0:
        ans += cnt(a)

print(int(ans))

Solution (Python):
N=int(input())
a=list(map(int,input().split()))

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

Solution (Python):
N = int(input())
As = list(map(int, input().split()))

powers = [0] * N
for i, A in enumerate(As):
    cnt = 0
    while A % 2 == 0:
        A /= 2
        cnt += 1
    powers[i] = cnt
print(sum(powers))

Solution (Python):
n = int(input())
a = [int(i) for i in input().split()]
count = 0
ji = True
for i in range(n):
    while a[i]%2==0:
        a[i] = a[i]//2
        count+=1
print(count)

Solution (Python):

import sys
sys_input = sys.stdin.readline
N = int(sys_input())
aaa = list(map(int, sys_input().split()))


aaa_remain = set(map(lambda x: x % 2, aaa))
if len(aaa_remain) == 1 and sum(aaa_remain) == 1:
    print(0)
    exit()

aaa_even = [a for a in aaa if a % 2 == 0]

n_divide = 0
is_dividable = True
for a in aaa_even:
    target_a = a
    while is_dividable:
        is_dividable = False if target_a % 2 else True
        if is_dividable:
            target_a = target_a//2
            n_divide += 1
    is_dividable = True

print(n_divide)

Solution (Python):
n = int(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)

Solution (Python):
import sys

if __name__ == '__main__':
	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)

Solution (Python):
n = int(input())

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

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

print(ans)

Solution (Python):
def log(n):
    res=0
    while n%2==0:
        res+=1
        n//=2
    return res

N=int(input())
a=list(map(int,input().split()))
ans=sum([log(ai) for ai in a])
print(ans)

Solution (Python):
input()
A = list(filter(lambda x: x % 2 == 0, map(int, input().split())))
count = 0
for i in A:
    tmp = i
    while True:
        if tmp % 2 == 0:
            count += 1
            tmp = int(tmp/2)
        else:
            break
print(count)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
ans = 0

for i in range(n):
    if a[i] % 2 == 1:
        continue

    temp = a[i]
    while temp > 0 and temp % 2 == 0:
        
        temp /= 2
        ans += 1

print(ans)

Solution (Python):
N=int(input())
A=list(map(int,input().split()))
B=[0]*N

def nanji(a,b):
    t = a
    count = 0
    while t % b == 0:
        t = t / b
        count = count +1
    return(count)

for i in range(N):
    B[i] = nanji(A[i],2)

print(sum(B))

Solution (Python):
n = int(input())
A = list(map(int, input().split()))

ans = 0
for a in A:
    for i in range(31):
        if a % (2**i) != 0:
            ans += i-1
            break

print(ans)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))

ans = 0

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

print(ans)

Solution (Python):
n = input()
A = list(map(int, input().split()))

cnt = 0
for a in A:
    while a % 2 == 0:
        a //= 2
        cnt += 1
print(cnt)

Solution (Python):
N=int(input())
l=list(map(int,input().split()))
l2=[n for n in l if n%2 ==0]
ans=0
for i in l2:
  while(i%2==0):
    ans+=1
    i /= 2
print(ans)

Solution (Python):
import math
n = int(input())
a = list(map(int,input().split()))
maxlog = int(math.log2(max(a)))
answer = 0
for _ in range(maxlog):
  a = [aa/2 for aa in a if aa%2==0]
  answer+= len(a)
  if not a:
    break
print(answer)

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

import numpy as np

N = int(readline())
A = np.array(read().split(),np.int32)

answer = 0
for _ in range(32):
    A = A[A%2 == 0]
    answer += len(A)
    A >>= 1

print(answer)

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
ans = 0
for i in range(N):
    while A[i] % 2 == 0:
        ans += 1 
        A[i] /= 2
print(ans)

Solution (Python):
n=int(input())
a = list(map(int,input().split()))
cnt=0
for i in range(n):
    while a[i]%2==0:
        a[i]=a[i]//2
        cnt+=1
print(cnt)

Solution (Python):
n = int(input())
ary = list(map(int,input().split()))
ans = 0
for i in range(len(ary)):
    a = ary[i]
    if a % 2 == 0:
        while a % 2 == 0:
            ans += 1
            a = a // 2
print(ans)

Solution (Python):
a = int(input())
lista = list(map(int, input().split()))
ans=0

for i in lista:
  while i % 2==0:
    i = i / 2
    ans += 1
    
print(ans)

Solution (Python):
def meu_map(l):
    for i in range(len(l)):
        l[i] = int(l[i])


n = int(raw_input())
array = raw_input().split()

meu_map(array)

fatores = 0
for e in array:
    while e != 1:
        if e % 2 == 0:
            e /= 2
            fatores += 1
        else:
            break

print(fatores)

Solution (Python):
n = int(input())
a = [ int(x) for x in input().split() ]
 
tot = 0
 
for i in a:
    x = i
    while x % 2 == 0:
        x /= 2
        tot += 1
 
print(tot)

Solution (Python):
n = int(input())
a = map(int, input().split())

count = 0 
for ai in a:
  x = ai
  while (x % 2 == 0):
    x /= 2
    count += 1
 
print(count)

Solution (Python):
n1 = int(input())

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

cont = 0
for e in lista:
    aux = e
    while(aux%2 == 0):
        aux /= 2
        cont += 1
        

print(cont)

Solution (Python):
n = int(raw_input())
input_list = map(int, raw_input().split())

total = 0

for num in input_list:
    partial = 0
    while (num % 2 == 0):
        partial += 1
        num /= 2
    total += partial

print(total)

Solution (Python):
n = int(input())
a = map(int, input().split())
 
cont = 0
 
for e in a:
    x = e
    while x % 2 == 0:
        x /= 2
        cont += 1
 
print(cont)

Solution (Python):

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

cnt = 0

for ai in A:
    x = ai
    while x % 2 == 0:
        x /= 2
        cnt += 1

print(cnt)

Solution (Python):
n = int(input())
ans = 0
for i in map(int,input().split()):
    a = i
    while a % 2 == 0:
        ans += 1
        a = a // 2
print(ans)