Problem:
 Score : 200 points    Problem Statement There are N positive integers written on a blackboard: A_1, ..., A_N .  Snuke can perform the following operation when all integers on the blackboard are even:   Replace each integer X on the blackboard by X divided by 2 .   Find the maximum possible number of operations that Snuke can perform.      Constraints  1 \leq N \leq 200  1 \leq A_i \leq 10^9         Input Input is given from Standard Input in the following format:  N  A_1  A_2 ... A_N       Output Print the maximum possible number of operations that Snuke can perform.        Sample Input 1 3
8 12 40      Sample Output 1 2  Initially, [8, 12, 40] are written on the blackboard.
Since all those integers are even, Snuke can perform the operation.  After the operation is performed once, [4, 6, 20] are written on the blackboard.
Since all those integers are again even, he can perform the operation.  After the operation is performed twice, [2, 3, 10] are written on the blackboard.
Now, there is an odd number 3 on the blackboard, so he cannot perform the operation any more.  Thus, Snuke can perform the operation at most twice.       Sample Input 2 4
5 6 8 10      Sample Output 2 0  Since there is an odd number 5 on the blackboard already in the beginning, Snuke cannot perform the operation at all.       Sample Input 3 6
382253568 723152896 37802240 379425024 404894720 471526144      Sample Output 3 8

Solution (Python):

n = int(input())
a = list(map(int,input().split()))
count = 0
status = True

while status:
    for i in range(n):
        if a[i] % 2 == 1:
            print(count)
            exit()
        a[i] = int(a[i] / 2)
    count += 1

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

Solution (Python):

def calc_times_divided_by_two(num):
  """
  Args:
    num (int)
  >>> calc_times__divided_by_two(8)
  3
  >>> calc_times__divided_by_two(7)
  0
  """
  cnt = 0
  while num % 2 == 0:
     num //= 2
     cnt += 1
  return cnt


n = int(input())
L = list(map(int, input().split()))
print(min(map(calc_times_divided_by_two, L)))

Solution (Python):
n = int(input())
a = [int(i) for i in input().split()]
pow_2 = [0] * n
for i in range(n):
    p2 = 0
    while a[i] % 2 == 0:
        p2 += 1
        a[i] //= 2 
    pow_2[i] = p2
print(min(pow_2))

Solution (Python):
import bisect,collections,copy,heapq,itertools,math,numpy,string
import sys
def S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def SS(): return map(str,sys.stdin.readline().rstrip().split())
def II(): return map(int,sys.stdin.readline().rstrip().split())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())

N = I()
A = LI()
cnt = 0
if len(A) != len([a for a in A if a % 2 == 0]):
  print(0)
  exit()

while True:
  cnt += 1
  A = [a / 2 for a in A]
  if len(A) != len([a for a in A if a % 2 == 0]):
    break
print(cnt)

Solution (Python):

def div(n):
	ans = 0
	while n % 2 == 0:
		n /= 2
		ans += 1
	return ans

n = int(input())
a = list(map(int, input().split()))
ans = min(map(div,a))
print(ans)

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

Solution (Python):



n=int (input())
l= [ int(x) for x in input().split() ]

dmax=0
for v in l:
   if v > dmax :
      dmax=v

dmin = dmax
for v in l:
   ct=0
   tmp = v
   while tmp%2 == 0:
      tmp /=2
      ct += 1
   if ct < dmin:
      dmin=ct

print(dmin)

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

Solution (Python):



num = int(input())
s = list(map(int,input().split()))

count = 0
while all(i % 2 == 0 for i in s):
    s = [i // 2 for i in s]
    count += 1

print(count)

Solution (Python):
def main():
    n = int(input())
    nums = list(map(int, input().split())) 
    exist_odd = False
    result = 0
    while True:
        for i in range(n):
            if nums[i] % 2 != 0:
                exist_odd = True
        if exist_odd:
            break
        nums = list(map(lambda x: x / 2, nums))
        result += 1
    print(result)
if __name__ == '__main__':
    main()

Solution (Python):
import math
n = int(input())
a = list(map(int, input().split()))
l = []
ans = int(math.sqrt(max(a)))
for i in a:
    if i%2!=0:
        ans = 0
    else:
        cnt = 0
        while i%2==0:
            i//=2
            cnt+=1
        ans = min(ans, cnt)
print(ans)

Solution (Python):
N=int(input())
A = list(map(int, input().split()))
def nidewareru(x):
  ans=0
  while (1):
    if x%2==0:
      x/=2
      ans+=1
    else:
      break
  return ans
    
mina=10000000
for a in A:
  mina=min(mina, nidewareru(a))
print(mina)

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

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

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

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

cnt = 1
while 1:
    for a in As:
        if a%(2**cnt)!=0:
            break
    else:
        cnt += 1
        continue
    break
print(cnt-1)

Solution (Python):
import numpy as np
 
N = int(input())
A = list(map(int,input().split()))
A = np.array(A)
cnt = 0
while all(A%2==0):
    for i in range(N):
        A[i] = A[i]//2
    cnt += 1
 
print(cnt)

Solution (Python):



num = int(input())
s = list(map(int,input().split()))

count = 0
while all (i % 2 == 0 for i in s):
    s = [i // 2 for i in s]
    count += 1
    
print(count)

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

print(min(L))

Solution (Python):
import numpy as np

N = int(input())
A = list(map(int,input().split()))
A = np.array(A)
cnt = 0
while all(A%2==0):
    for i in range(N):
        A[i] = A[i]//2
    cnt += 1

print(cnt)

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

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

print(cnt)

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

ans = 1000000000

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

print(ans)

Solution (Python):
import sys

import math


from collections import deque

from fractions  import gcd


n=int(input())
a=list(map(int,input().split()))
i=0
f=False
while True:
    for j in range(n):
        if (a[j]>>i)&1:
            f=True
            break
    else:
        i+=1
    if f:
        break
print(i)

Solution (Python):
n = int(input())
A = list(map(int,input().split()))
ans = 10**9
tmp = 0
for i in range(n):
  while True:
    if A[i]%2==0:
      A[i] = A[i]//2
      tmp += 1
    else:
      ans = min(ans,tmp)
      tmp = 0
      break

print(ans)

Solution (Python):
import sys
import numpy as np
from collections import Counter, deque

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


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

    res = 0
    while not any(np.mod(A, 2)):
        res += 1
        A //= 2

    print(res)


if __name__ == '__main__':
    resolve()

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

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

ans = float('inf')

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

    else:
        print(0)
        exit()
print(ans)

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

ans = ""
for A in a:
  if A % 2 != 0:
    print(0)
    exit()
  cnt = 0
  while A%2==0:
    A /=2
    cnt += 1
  if ans == "" or ans > cnt: ans = cnt
print(ans)

Solution (Python):
def resolve():
  n = int(input())
  a = list(map(int, input().split()))
  ans = 1e9
  for x in a:
    tmp = 0
    while x > 1 and x % 2 == 0:
      x //= 2
      tmp += 1
    ans = min(ans, tmp)
  print(ans)
  return

if __name__ == "__main__":
  resolve()

Solution (Python):
import sys
from collections import Counter
from collections import deque
import math
import fractions
def input(): return sys.stdin.readline().strip()
def mp(): return map(int,input().split())
def lmp(): return list(map(int,input().split()))

n=int(input())
a=lmp()
c=a[0]
for i in range(1,n):
    c=fractions.gcd(c,a[i])
ans=0
while True:
    if c%2==0:
        ans+=1
        c=c//2
    else:
      break
print(ans)

Solution (Python):
def resolve():
    n = int(input())
    a = list(map(int, input().split()))
    OK = True
    ans = 0
    while OK:
        for i in range(n):
            if a[i] % 2 == 0:
                a[i] //= 2
            else:
                OK = False
                break
        if OK:
            ans += 1
    print(ans)
resolve()

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

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

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

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

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

res = min(map(devide, numbers))
print(res)

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

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

print(ans)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
i = 0 
m = 0 
while m < 1:
    i = i +1
    for j in range(N):
        if A[j] % 2 != 0:
            m = m + 1
        else:
            A[j] = A[j] / 2
print(i-1)

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

cnt = 0
flag = 1
while flag:
    for i in range(n):
        a = A[i]
        if a % 2 != 0:
            flag = 0
            break
        else:
            A[i] = a // 2
    else:
        cnt += 1
    
print(cnt)

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

cnt = 0
flag = 1
while flag:
    for i in range(n):
        a = A.pop(0)
        if a % 2 != 0:
            flag = 0
            break
        else:
            A.append(a // 2)
    else:
        cnt += 1
    
print(cnt)

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

def count_time(a):
  c = 0
  while a % 2 == 0:
    c += 1
    a //= 2
  return c

ans = 10**10
for a in A:
  ans = min(ans, count_time(a))

print(ans)

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

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

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

ans = min(map(divide_number,numbers))
print(ans)

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

for i in range(10**10):
  for j in range(n):
    if a[j]%2 != 0:
      print(count)
      exit()
    else:
      a[j] = a[j]//2
  count += 1

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

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

Solution (Python):
N = int(input())
A = map(int, input().split())
def cal(n):
    cnt = 0
    while n % 2 == 0:
        n //= 2
        cnt += 1
    return cnt
print(min(map(cal, A)))

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
count = 0
doing = True
while doing:
  for i in range(len(A)):
    if A[i] & 1:
      doing = False
      count -= 1
      break
    A[i] //= 2
  count += 1
print(count)

Solution (Python):




import sys
from fractions import gcd
import math
from math import ceil,floor
import collections








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



ans = 0
while True:
    for i in range(0,N):
        if A[i]%2==1:
            print(ans)
            sys.exit()
        else:
            A[i]=A[i]//2
            if i==N-1:
                ans+=1

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
flg = True
cnt = 0
total = 0

while flg:
    for i in range(N):
        if A[i] % 2 == 0:
            A[i] = A[i] // 2
            cnt += 1
    if cnt == N:
        total += 1
    else:
        flg = False
    cnt = 0
print(total)

Solution (Python):


def div(n):
    return int(n / 2)

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

r = 0
flag = False
while (True):
    for x in A:
        if x % 2 == 1:
            flag = True
            break

    if (flag):
        break

    r += 1
    A = list(map(div, A))    
    
print(r)

Solution (Python):
n = input()
li = list(map(int, input().split()))
count = 0



while all(a % 2 == 0 for a in li):
    li = [ a / 2 for a in li]
    count += 1

print(count)

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


input()
print(min(map(f, input().split())))

Solution (Python):

n = int(input())
m = list(map(int, input().split())) 
asmt = [0]*n
cnt = 0


while True:
    a = list(map(lambda x: x*(1/2)**(cnt+1), m))
    for i in range(n):
        asmt[i] = a[i].is_integer() 
        
    if all(asmt) == False:
        break 
    else: cnt = cnt+1

print(cnt)

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

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

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

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

print(c)

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

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

ans = min(map(calc, A))

print(ans)

Solution (Python):
from math import log2

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

res = 10**9
for v in a:
    cnt = 0
    while v % 2 == 0:
        v /= 2
        cnt += 1
    res = min(cnt, res)
print(res)

Solution (Python):
n=int(input())
a = list(map(int,input().split()))
t=0
while all((i%2==0 for i in a)):  

    a=[i/2 for i in a]  
    
    t += 1

print(t)

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

a = list(map(int, input().split()))
b = []
for i in range(N):
    ans = 0
    odd = 0
    while odd == 0:
        if a[i] % 2 == 0:
            a[i] = int(a[i]/2)
            ans += 1
        else:
            odd += 1
    b += [ans]

print(min(b))

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

count = 0

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

print(count)

Solution (Python):
N = int(input())
A_list = list(map(int, input().split()))
count = 0

while (True):
    exist_odd = False
    for i in range(N):
        if (A_list[i] % 2) != 0:
            exist_odd = True

    if exist_odd:
        break
    
    for i in range(N):
        A_list[i] = A_list[i] / 2

    count = count + 1

print(count)

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

ans = 10**9
for num in A:
    count = 0
    for _ in range(ans):
        if num % 2 == 1:
            break
        num /= 2
        count += 1
    ans = min(ans,count)
print(ans)

Solution (Python):
N = int(input())
As = [int(c) for c in input().split()]
counter = 0


while True:
    for i in range(N):
        if As[i] % 2 != 0:
            break
        As[i] = int(As[i] / 2)
    else:
        counter += 1
        continue
    break

print(counter)

Solution (Python):
N = int(input())
A = [int(i) for i in input().split()]
import fractions
from functools import reduce

def gcd(*numbers):
    return reduce(fractions.gcd, numbers)

def gcd_list(numbers):
    return reduce(fractions.gcd, numbers)
tmp =gcd_list(A)
for i in range(100):
    if tmp == 2**i:
        print(i)
        break

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

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

cnt = 0
while True:
    amari = 0
    for i in range(N):
        amari += A[i] % 2
        A[i] /= 2
        if amari != 0:
            print(cnt)
            exit()
    cnt += 1

Solution (Python):
n = input()
a = list(map(int,input().split()))
count = 0
flag = True
while flag:
    for i in range(len(a)):
        if a[i] % 2 != 0:
            print(count)
            flag = False
            break
    else:
        count += 1
        a = [ i / 2 for i in a]

Solution (Python):
n = int(input())
a = []
A = input().split()
f = False
for i in range(n):
    a.append(int(A[i]))
    if int(A[i]) % 2 != 0:
        f = True
ans = 0

if f:
    print(ans)
else:
    while True:
        
        for i in range(len(a)):
            nx = int(a[i])
            if nx % 2 != 0:
                f = True
            a[i] = nx / 2
        if f:
            
            break
        else:
            ans += 1
    print(ans)

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

Solution (Python):
n=int(input())
a=[int(i) for i in input().split()]
b=[]
ans=0
ok=False
while True:
    for i in a:
        if i%2!=0:
            print(ans)
            ok=True
            break
        else:
            b.append(i//2)
    if ok:
        break
    ans+=1
    a=b
    b=[]

Solution (Python):

import sys
sys.setrecursionlimit(10**7)

import numpy as np

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

c = 0

def div(a):
    global c
    for i in a:
        if i%2==1:
            print(c)
            sys.exit()
    ll = list(map(lambda x : x/2, a))
    c += 1
    div(ll)

div(a)

Solution (Python):

import sys
sys.setrecursionlimit(10**7)

import numpy as np

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

c = 0

def div(a):
    global c
    for i in a:
        if i%2==1:
            print(c)
            sys.exit()

    ll = list(map(lambda x : x/2, a))
    c += 1
    div(ll)

div(a)

Solution (Python):
a = int(input(""))
b = input("").split(" ")
c = 0
d = []

for i in range(a):
	c = 0
	while (int(b[i]) % 2 == 0):
		b[i] = int(b[i]) / 2
		c += 1
	d.append(c)
print(min(d))

Solution (Python):
import numpy as np
n=int(input())
a=np.array(list(map(int,input().split())))
b=0
while np.all(a%2==0):
	a=a/2
	b+=1
	
print(b)

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

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

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

count = 0
flag = True

while flag == True :
    for i in range(N):
        if A[i]%2 == 1:
            print(count)
            flag = False
            break
        else:
            A[i] = A[i]/2
    count += 1

Solution (Python):

n = int(input())

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

c = 0


def func(num: int, array: [int], count) -> int:
    for i in range(num):
        if i + 1 != num:
            if array[i] % 2 == 0:
                array[i] = array[i] / 2
                continue
            else:
                break
        else:
            if array[i] % 2 == 0:
                count += 1
                array[i] = array[i] / 2
                count = func(num, array, count)
    return count


print(func(n, a, c))

Solution (Python):
input()
print(min(map(lambda a: int(a) & (-int(a)), input().split())).bit_length() - 1)

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

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

count = 0
finished = False
while True:
    for index, value in enumerate(num):
        if value % 2 == 0:
            num[index] = value / 2
        else:
            finished = True
            break
    if finished:
        break
    else:
        count += 1
print(count)

Solution (Python):
_ = input()
numbers = list(map(int,input().split(' ')))

count = 0
finished = False
while True:
    for index, value in enumerate(numbers):
        if value % 2 == 0:
            numbers[index] = value / 2
        else:
            finished = True
            break
    if finished:
        break
    else:
        count += 1
print(count)

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

Solution (Python):
n = int(input())
A = [int(s) for s in input().split()]

div_a = 2
count = 0
while 1 :
    flag = 0
    for a_i in A :
        if a_i % div_a != 0 :
            flag = 1
    if flag == 1 :
        break
    else :
        div_a = div_a * 2
        count = count + 1
print(count)

Solution (Python):
"""
N = list(map(int,input().split()))
S = [str(input()) for _ in range(N)]
S = [list(map(int,list(input()))) for _ in range(h)] 
print(*S,sep="")
"""

import sys
sys.setrecursionlimit(10**6)
input = lambda: sys.stdin.readline().rstrip()

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

count = 0

while True:
    for _ in range(n):
        if a[_]%2==0:
            a[_]//=2
        else:
            break
    else:
        count+=1
        continue
    break
print(count)

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

while True:
  for i in range(0,n):
    if(a[i]%2 != 0):
      print(c)
      exit()
    else:
      a[i] = int(a[i]/2)
  c = c + 1
print(c)

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

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

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

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

Solution (Python):
import numpy as np
import sys

n = int(input())
a = np.array(list(map(int, input().split())))

cnt = 1

if np.any(a%2==1):
    print(0)
    sys.exit()

while True:
    a2 = a % 2**cnt
    if np.all(a2==0):
        cnt += 1
        continue
    else:
        print(cnt-1)
        break

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

Solution (Python):
a = input()
b = input().split(' ')
nums=[int(i) for i in b]
divide_count=0
while True:
  for index,num in enumerate(nums):
    if int(num)%2==1:
      print(divide_count)
      exit()
    else:
      nums[index]=num/2
  divide_count +=1

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

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

def func(i, c):
    return func(i // 2, c + 1) if i % 2 == 0 else c

print(min([func(i, 0) for i in A]))

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
x = 0
break_loop = False
while True:
    for i in range(n):
        if a[i]%2 != 0:
            print(x)
            break_loop = True
            break    
        else:
            a[i] = a[i]/2
    x += 1
    if break_loop:
        break

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

count = 0
flag = True

while flag:
    for i in range(n):
        if a[i] %2 != 0:
            flag = False
        else:
            a[i] = a[i]//2
    if flag == False:
        break
    count = count+1

print(count)

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

count = 0
flag = True

while flag:
    for i in range(n):
        if a[i] % 2 != 0:
            flag = False

    if flag == False:
        break

    for i in range(n):
        a[i] //= 2
    count = count + 1
print(count)

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

flag = True
cnt = 0
n = len(A)
while flag:
    for i in range(n):
        if A[i]%2 == 0:
            A[i]/=2
        else:
            print(cnt)
            exit()
    cnt += 1

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

n = int(readline())
a = [int(x) for x in readline().split()]
ans = float('inf')
for x in a:
    ans = min(ans, len(bin(x)) - bin(x).rfind('1') - 1)
print(ans)

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

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

n = int(readline())
a = [int(x) for x in readline().split()]
ans = float('inf')
for x in a:
    ans = min(ans, len(bin(x)) - bin(x).rfind('1') - 1)
print(ans)

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

ans = 0
while(all(i % 2 == 0 for i in A)):
    ans += 1
    A = [int(i / 2) for i in A]

print(ans)

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

while all(a % 2 == 0 for a in A):
    A = [a/2 for a in A]
    count += 1

print(count)

Solution (Python):

def inp():
    return(int(input()))



def inlist():
    return(list(map(int, input().split())))



def instr():
    s = input()
    return(list(s[:len(s)]))



def invr():
    return(map(int, input().split()))


N = inp()
A = inlist()

s = sum(A)
c = 0
f = True
while f:
    for i in range(N):
        if A[i] % 2 != 0:
            f = False
            break
        A[i] = A[i] // 2
    if not f:
        break
    c += 1
print(c)

Solution (Python):
a=int(input())
b=list(map(int, input().split()))
c=[0]*a
for i in range(a):
  num=b[i]
  while num%2==0 and num>0:
    c[i]+=1
    num=num//2
    
print(min(c))

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

while all(a%2==0 for a in A):
    A=[a/2 for a in A]
    count+=1
print(count)

Solution (Python):






import sys
input = sys.stdin.readline

import math

import bisect
from collections import defaultdict
from collections import deque
from functools import lru_cache






MOD = 10**9+7
INF = float('inf')






def inputI(): return int(input().strip())
def inputS(): return input().strip()
def inputIL(): return list(map(int,input().split()))
def inputSL(): return list(map(str,input().split()))
def inputILs(n): return list(int(input()) for _ in range(n))
def inputSLs(n): return list(input().strip() for _ in range(n))
def inputILL(n): return [list(map(int, input().split())) for _ in range(n)]
def inputSLL(n): return [list(map(str, input().split())) for _ in range(n)]


def Yes(): print("Yes"); return
def No(): print("No"); return


def inv(n): return pow(n, MOD-2, MOD)


kaijo_memo = []
def kaijo(n):
  if(len(kaijo_memo) > n):
    return kaijo_memo[n]
  if(len(kaijo_memo) == 0):
    kaijo_memo.append(1)
  while(len(kaijo_memo) <= n):
    kaijo_memo.append(kaijo_memo[-1] * len(kaijo_memo) % MOD)
  return kaijo_memo[n]

gyaku_kaijo_memo = []
def gyaku_kaijo(n):
  if(len(gyaku_kaijo_memo) > n):
    return gyaku_kaijo_memo[n]
  if(len(gyaku_kaijo_memo) == 0):
    gyaku_kaijo_memo.append(1)
  while(len(gyaku_kaijo_memo) <= n):
    gyaku_kaijo_memo.append(gyaku_kaijo_memo[-1] * pow(len(gyaku_kaijo_memo),MOD-2,MOD) % MOD)
  return gyaku_kaijo_memo[n]

def nCr(n,r):
  if(n == r):
    return 1
  if(n < r or r < 0):
    return 0
  ret = 1
  ret = ret * kaijo(n) % MOD
  ret = ret * gyaku_kaijo(r) % MOD
  ret = ret * gyaku_kaijo(n-r) % MOD
  return ret


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 make_divisors(n):
  divisors = []
  for i in range(1, int(n**0.5)+1):
    if n % i == 0:
      divisors.append(i)
      if i != n // i: 
        divisors.append(n//i)
  return divisors


def lcm(a, b):
    return a * b // gcd (a, b)


def count_bit(n):
  count = 0
  while n:
    n &= n -1
    count += 1
  return count


def Base_10_to_n(X, n):
  if X//n:
    return Base_10_to_n(X//n, n)+[X%n]
  return [X%n]

def Base_n_to_10(X, n):
  return sum(int(str(X)[-i])*n**i for i in range(len(str(X))))


def int_log(n, a):
  count = 0
  while n>=a:
    n //= a
    count += 1
  return count





N = inputI()
print( min(int_log((x&(-x)),2) for x in inputIL() ))