import math

n = eval(input())

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

ans = float("inf")

for i in a:

    ans = min(ans, len(bin(i)) - bin(i).rfind("1") - 1)

print((round(ans)))
N = int(eval(input()))

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

cout = 0

while all(a % 2 == 0 for a in A):

  A = [a/2 for a in A]

  cout += 1

print(cout)
import math

n = eval(input())
a = list(map(int, input().split()))
ans = float("inf")
for i in a:
    ans = min(ans, len(bin(i)) - bin(i).rfind("1") - 1)
print((round(ans)))

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

-import math - -n = eval(input()) -a = list(map(int, input().split())) -ans = float("inf") -for i in a: -    ans = min(ans, len(bin(i)) - bin(i).rfind("1") - 1) -print((round(ans))) +N = int(eval(input())) +A = list(map(int, input().split())) +cout = 0 +while all(a % 2 == 0 for a in A): +    A = [a / 2 for a in A] +    cout += 1 +print(cout)