n=int(eval(input()))

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



c_list=[]

for i in list:

    count=0

    while True:

            

        if i%2==0:

            i=i/2

            count+=1

        else:

            break

    c_list.append(count)



    

print((min(c_list)))

    
# Your code here!

n=int(eval(input()))



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

count_list=[]



for i in range(n):

    num=a_list[i]

    count=0

    while True:

        if num%2==0:

            num//=2

            count+=1

        else:

            break

    count_list.append(count)



#print(count_list)   

print((min(count_list)))
n = int(eval(input()))
list = [int(i) for i in input().split()]
c_list = []
for i in list:
    count = 0
    while True:
        if i % 2 == 0:
            i = i / 2
            count += 1
        else:
            break
    c_list.append(count)
print((min(c_list)))

# Your code here!
n = int(eval(input()))
a_list = [int(i) for i in input().split()]
count_list = []
for i in range(n):
    num = a_list[i]
    count = 0
    while True:
        if num % 2 == 0:
            num //= 2
            count += 1
        else:
            break
    count_list.append(count)
# print(count_list)
print((min(count_list)))

+# Your code here! -list = [int(i) for i in input().split()] -c_list = [] -for i in list: +a_list = [int(i) for i in input().split()] +count_list = [] +for i in range(n): +    num = a_list[i] -        if i % 2 == 0: -            i = i / 2 +        if num % 2 == 0: +            num //= 2 -    c_list.append(count) -print((min(c_list))) +    count_list.append(count) +# print(count_list) +print((min(count_list)))