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



Sample input:
3
8 12 40


Sample output:
2

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
c = 0
f=0
while f==0:
    B = [i%2 for i in A]
    A = [i/2 for i in A]
    if sum(B) != 0:
        f+=1
    else:
        c+=1
print(c)

Submission status: Accepted

Solution code:
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
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))

n = inp()
a = inpl()
res = float('inf')
for i in a:
    cnt = 0
    while True:
        if i%2:
            res = min(res, cnt)
            break
        i //= 2
        cnt += 1
print(res)

Submission status: Accepted

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

num_divided = 0

while len(list(filter(lambda x: x % 2 == 0, a))) == n:
  a = list(map(lambda x: x / 2, a ))
  num_divided += 1

print(num_divided)

Submission status: Accepted

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

def iseven(i,num_list):
  for num in num_list:
    if num % 2 != 0:
      return False
  return True

num_divided = 0

while iseven(n,a) :
  a = list(map(lambda x: x / 2, a ))
  num_divided += 1

print(num_divided)

Submission status: Accepted

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

def iseven(i,num_list):
  count = 0
  for num in num_list:
    if num % 2 != 0:
      return False
  return True

num_divided = 0

while iseven(n,a) :
  a = list(map(lambda x: x / 2, a ))
  num_divided += 1

print(num_divided)

Submission status: Accepted

Solution code:
def checkCanHalf(ary):
  for item in ary:
    if(item % 2 != 0):
      return False
  return True

n = range(int(input()))
ary = list(map(int, input().split()))
cnt = 0

while checkCanHalf(ary) == True:
  for i in range(len(ary)):
    ary[i] = ary[i]/2
  cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
N = int(input())
A = [int(x) for x in input().split()]
result = float('inf')
for i in range(N):
  r=0
  while A[i]%2==0:
    A[i]=A[i]/2
    r +=1
  result=min(result,r)
print(result)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
# import collections
# import math
# import string
# import bisect
# import re
# import itertools
# import statistics

def main():
    n, *numbers = (int(x) for x in sys.stdin.read().split())
    still_can_be_divided = True
    count = 0
    while still_can_be_divided:
        for i in range(n):
            if numbers[i] % 2 == 0: 
                numbers[i] //= 2
            else: 
                still_can_be_divided = False
        if still_can_be_divided:
            count += 1        

    print(count)

if __name__ == "__main__":
    # execute only if run as a script
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
num = int(raw_input())
list = map(int, raw_input().split())

i = 0
while 1 not in map(lambda x: x % 2, list):
 list = map(lambda x: x >> 1, list)
 i += 1

print i

Submission status: Accepted

Solution code:
from sys import stdin

def main():
    N = int(stdin.readline().rstrip())
    data = [int(x) for x in stdin.readline().rstrip().split()]
    counter = 0
    isBreak = False
    while(True):
        for d in data:
            if d % 2 != 0:
                isBreak = True
                break
        if isBreak:
            break
        data = [x/2 for x in data]
        counter += 1
    print(counter)

if __name__ == "__main__":
    main()

Submission status: Accepted

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

c = 0
ex_o = False
while (True):
    for x in range(n):
        if list[x] % 2 == 1:
            ex_o = True
    
    if ex_o:
        break

    for x in range(n):
        list[x] /= 2

    c += 1

print(c)

Submission status: Accepted

Solution code:
import numpy as np
N=int(input())
A=list(map(int,input().split()))
A=np.array(A)
ans=2**9
for i in A:
  cnt=0
  while i%2==0:
    i=i/2
    cnt+=1
  if ans > cnt:
    ans=cnt
    
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import numpy as np
input()
x = np.array(input().split(),dtype=np.int32)

ans = 0
while (x%2 == 0).all():
  x = x//2
  ans += 1
print(ans)

Submission status: Accepted

Solution code:
import numpy as np
input()
x = np.array(input().split(),dtype=np.int32)
 
answer = 0
while (x%2==0).all():
  x //= 2
  answer += 1
print(answer)

Submission status: Accepted

Solution code:
N = int(input())
numbers = list(map(int, input().split()))
canDevide = True
count = 0;
while canDevide :
  for i in range(N) :
    if numbers[i]%2 == 0 :
      numbers[i] /= 2
    else :
      canDevide = False
      break
  if canDevide :
    count += 1
print(count)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def aaa(x: int) -> bool:
    return x % 2 == 0


def bbb(x: int) -> int:
    return x / 2


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

flag = True
ans = 0
while(flag):
    li = list(filter(aaa, li))
    li = list(map(bbb, li))
    if(len(li) == n):
        ans += 1
    else:
        flag = False
print(ans)

Submission status: Accepted

Solution code:
# coding=utf-8

if __name__ == '__main__':
    N = int(input())
    li = list(map(int, input().split()))

    cnt = 0
    frag = 0

    while True:
        for i in range(N):
            if li[i] % 2 == 1:
                frag = 1
                break

            else:
                li[i] = li[i] / 2

        if frag == 1:
            break

        cnt = cnt + 1

    print(cnt)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))
b = [0] * n

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

Submission status: Accepted

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

while list(map(lambda x: x%2, a)).count(0)==len(a):
    a = list(map(lambda x: x/2, a))
    c+=1

print(c)

Submission status: Accepted

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

N =int(input())
A =map(int, input().split())
ans =min(map(f,A))
print(ans)

Submission status: Accepted

Solution code:
n = int(input())
list_a = list(map(int, input().split()))
count = 0
while True:
  sub_list = [int(one_a / 2) for one_a in list_a if one_a % 2 == 0]
  if len(list_a) == len(sub_list):
    count += 1
    list_a = sub_list
  else:
    print(count)
    exit()

Submission status: Accepted

Solution code:
import sys

def main():
    N = int(input())
    A = list(map(lambda i: int(i), input().split(' ')))
    count = 0
    while True:
        for index, a in enumerate(A):
            if a % 2 == 0:
                A[index] = a // 2
            else:
                print(count)
                sys.exit()
        count += 1
    print(count)

main()

Submission status: Accepted

Solution code:
n = int(input())
a = list(int(x) for x in input().split())

flag = 1
cnt = 0

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

print(cnt-1)

Submission status: Accepted

Solution code:
n=input()
a = list(map(int,input().split()))
result = float('inf')
for i in a:
    p = 0
    while i % 2 ==0:
        i//=2
        p +=1
    if p < result:
        result = p
print(result)

Submission status: Accepted

Solution code:
def div2(x: int):
    if x % 2 == 0:
        return int(x / 2)
    else:
        return False


def judge(l: list, count: int):
    l = list(map(div2, l))

    if False in l:
        print(count)
        return
    else:
        judge(l, count + 1)


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

judge(a_list, 0)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
count = 0
flag = ''

while True:
    for index, a in enumerate(A):
        if a % 2 != 0:
            flag = 'true'
        A[index] = A[index] / 2
    if flag == 'true':
        break
    count += 1

print(count)

Submission status: Accepted

Solution code:
a = input()
b = input()
a = int(a)
b = b.split()
b = [int(s) for s in b]
c = 0
flag = True
while True:
    
    for i in range(a):
        if b[i] % 2 != 0:
            flag = False
        b[i] = b[i] / 2
        
    if flag == False:
        break
    c += 1

    

    
print(c)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int,input().split(' ')))
count = 0;
flag =True
while True:
    for i in a :
        if i % 2 != 0 :
            flag=False
            break
    if flag :
        a = list(map(lambda x: x/2 , a))
        count=count+1
    else:
        break
    
print(str(count))

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int,input().split()))
result = float('inf') 
for i in a:
    result = min(result,len(bin(i))-bin(i).rfind('1')-1)
print(result)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import numpy as np
N = int(input())
box = list(map(int, input().split()))
box = np.array(box)
count=0
while(True):
  if any([i % 2 != 0 for i in box]):
    break
  elif all([i % 2 == 0 for i in box]):
    box /= 2
    count +=1
print(count)

Submission status: Accepted

Solution code:
n = int(input())
lists = list(map(int,input().split()))



def checker(lists):
	sns = sum([a%2 for a in lists])
	#print(sns)
	if sns==0:
		lists = [a/2 for a in lists]
		return lists
	else:
		return 0

cnt = 0
while(1):
	lists=checker(lists)
	if lists != 0:
		cnt = cnt+1
	else:
		break

print(cnt)

Submission status: Accepted

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

d = 1
count = -1
flag = True
while flag:
  count += 1
  d *= 2  
  
  for i in range(n):
    if A[i] % d != 0:
      flag = False
        
print(count)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import numpy as np
n=int(input())
lis=list(map(int,input().split()))

ls = np.array(lis)

num=0
while np.all(ls%2==0):
    num+=1
    ls = ls/2
print(num)

Submission status: Accepted

Solution code:
n = int(input())
list_a = list(map(int, input().split()))

cnt = 0
while all(map(lambda x: x%2 == 0, list_a)):
    list_a = list(map(lambda x: x/2, list_a))
    cnt +=1

print(cnt)

Submission status: Accepted

Solution code:
x = int(input())
y = [int(i) for i in input().split()]

def fun(y):
  cnt = 0

  for i in y:
    if (i % 2) != 0:
      cnt += 1

  return cnt

def fun2(y):
  tmp = [i/2 for i in y]
  return tmp

ans = 0

while True:
  res = fun(y)
  if res >= 1:
    print(ans)
    break
  else:
    ans += 1
    y = fun2(y)

Submission status: Accepted

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

n = int(input())
a = map(int, input().split())
ans = min(map(how_many_times_divisible, a))

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
count = 0
RET = 0

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

print(count)

Submission status: Accepted

Solution code:
# input
# ---
# N
# A[1] A[2] A[3] ...
# ---
N = int(input())
A = list(map(int, input().split()))

# 操作の回数をカウント
count = 0
# 奇数が1つもなければ exist_odd=0
exist_odd = 0

# Trueの間ずっと続ける
while True:
    for i in range(N):
        if A[i] % 2 == 1:
            exist_odd = 1
        else:
            A[i] /= 2

    if exist_odd == 1:
        break
    else:
        count += 1

print(count)

Submission status: Accepted

Solution code:
N=int(input())
S=list(map(int,input().split()))
shingi=True
total=0
while shingi==True:
    count=0
    for i in S:
        if i%2==0:
            count+=1
        else:
            shingi=False
    if count==len(S):
        total+=1
    S=list(map(lambda x:x/2,S))
print(total)

Submission status: Accepted

Solution code:
import numpy as np

a = int(input())
b = np.array([int(x) for x in input().split()])

if(a!=len(b)):
	print('the array size is different')
else:
	c = b%2
	d = b/2
	count = 0
	while sum(c)==0:
		count += 1
		c = d%2
		d = d/2
	print(count)

Submission status: Accepted

Solution code:
n, *a = map(int, open(0).read().split())

min = 100
for i in a:
    count = 0
    while i % 2 == 0:
        i /= 2
        count += 1
    if count < min:
        min = count

print(min)

Submission status: Accepted

Solution code:
n = int(input())
alist_s = input().rstrip().split(" ")
alist = []
for i in range(n):
    alist.append(int(alist_s[i]))
flag = True
c = 0
while flag == True:
    ac = 0
    for i in alist:
        if i % 2 == 0:
            ac += 1
        else:
            flag = False
    if ac == len(alist):
        c += 1
        for j in range(len(alist)):
            alist[j] = int(alist[j] / 2)
print(c)

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 25,Oct,2019
"""

import sys
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 7)

N = int(readline().rstrip())
lis = list(map(int, readline().rstrip().split()))


def divide2cnt(N):
    lis = []
    for i in N:
        cnt = 0
        while i % 2 == 0:
            i /= 2
            cnt += 1
        lis.append(cnt)

    return sorted(lis)[0]


print(divide2cnt(lis))

Submission status: Accepted

Solution code:

N = int(input())
l = list(map(int,input().split()))
cnt = 0

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

print(cnt)

Submission status: Accepted

Solution code:
#input
N = int(input())
A = list(map(int,input().split()))
#b = int(input())
 
#s = [0,0,0]
#s[0] = int(input/100)
#s[1] = int(input/10 - s[0]*10)
#[2] = int(input%10)
 
count = 0
flag = 0
 
#loop
while(1):
  for i in range(N):
    
    if A[i] %2 == 1:
      flag = 1
    else:
      temp = A[i]/2
      A[i] = temp;
  
  #judge
  if flag == 1:
    break
  else:
    count +=1
    #print(A)
 
#print('result')
#print(A)
print(count)

Submission status: Accepted

Solution code:
N = int(input())
A_list = [int(num) for num in input().split()]

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

Submission status: Accepted

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

count = 0
flag = 0

while(1):
    for i in range(n):
        if a[i] %2 == 1:
            flag = 1
        else:
            temp = a[i]/2
            a[i] = temp;
    if flag == 1:
        break
    else:
        count += 1
print(count)

Submission status: Accepted

Solution code:
#input
N = int(input())
A = list(map(int,input().split()))
#b = int(input())

#s = [0,0,0]
#s[0] = int(input/100)
#s[1] = int(input/10 - s[0]*10)
#[2] = int(input%10)

count = 0
flag = 0

#loop
while(1):
  for i in range(N):
    
    if A[i] %2 == 1:
      flag = 1
    else:
      temp = A[i]/2
      A[i] = temp;
  
  #judge
  if flag == 1:
    break
  else:
    count +=1
    #print(A)

#print('result')
#print(A)
print(count)

Submission status: Accepted

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

ans = 0
while all(map(lambda x: x%2 == 0, a)):
    a = list(map(lambda x: int(x/2), a))
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
n=int(input())
alis=list(map(int,input().split()))
blis=[]
for i in alis:
	cnt=0
	while i%2==0:
		i= i/2
		cnt+=1
	blis.append(cnt)
print(min(blis))

Submission status: Accepted

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

r = 0
even = all(n % 2 == 0 for n in A)
while even is True:
    A = [n //2 for n in A]
    r = r +1
    even = all(n % 2 == 0 for n in A)
print(r)

Submission status: Accepted

Solution code:
n = int(input())
nums = list(map(int, input().split(" ")))
res = 0
even = all(num % 2 == 0 for num in nums)
while even is True:
	nums = [num//2 for num in nums] 
	res = res + 1
	even = all(num % 2 == 0 for num in nums)
print(res)

Submission status: Accepted

Solution code:
N = int(input())
A_lst  = list(map(int, input().split()))
                                                                                                                                                                                                                                              
count = 0
while True:
    A_lst = [a//2 for a in A_lst if a%2 == 0]
    if len(A_lst) != N:
        break
    count += 1
print(count)

Submission status: Accepted

Solution code:

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

c = 0

def dividable(A):
    for a in A:
        if a % 2 != 0:
            return False
    return True

def divide(A):
    return [a // 2 for a in A]

while dividable(A):
    A = divide(A)
    c += 1

print(c)

Submission status: Accepted

Solution code:
# B - Shift only

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

count = 0
for i in range(max(A)//2):
    for j in range(N):
        if A[j] % 2 == 1:
            print(count)
            exit()
        else:
            A[j] = A[j]//2
    count += 1

Submission status: Accepted

Solution code:
N = int(input())
list = [int(j) for j in input().split()]
ans = 0
while True:
  cnt = 0
  for i in range(N):
    if list[i] == 0:
      break
    if list[i] % 2 == 0:
      list[i] /= 2
      cnt += 1  
  if cnt == N:
    ans += 1
  else:
    print(ans)
    break

Submission status: Accepted

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

Submission status: Accepted

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

res = 0

while True:
  if 1 in [ai%2 for ai in a]:
    break

  a = [ai//2 for ai in a]

  res += 1

print(res)

Submission status: Accepted

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

flg = False
res = 0

while True:
  for i in range(n):
    if a[i]%2 == 1:
      flg = True
    a[i] //= 2

  if flg:
    break

  res += 1

print(res)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))
count = 0
only_even = True
while only_even:
  for i in range(n):
    if a[i] % 2 != 0:
      only_even = False
    
  if only_even == False:
    break

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

print(count)

Submission status: Accepted

Solution code:
n=int(input())
X = list(map(int,input().split()))
h = True
count = 0
while h:
  for i in range(n):
    if X[i] %2 == 0 :
      X[i] = X[i]/2
    else:
      h = False
      break
  count+=1
  
print(count-1)

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(lambda x: int(x), input().split()))
ans=100
for i in a:
    tmp=0
    while True:
        if i%2==0:
            i/=2
            tmp+=1
        else:
            if ans > tmp:
                ans=tmp
            break
print(ans)

Submission status: Accepted

Solution code:
import numpy as np
n = int(input())
l = np.array(list(map(int, input().split())))
c = 0
while True:
  if len(l[l%2==0]) != len(l):
    print(c)
    break
  l /= 2
  c += 1

Submission status: Accepted

Solution code:
def judgeEven(s):
  for list in s:
  	if list % 2 != 0:
  		return False

  return True
num = input()
s = input().split(" ")
s_int = [int(n) for n in s]
count = 0
while(judgeEven(s_int)):
  s_int = [i/2 for i in s_int]
  count = count + 1

print(count)

Submission status: Accepted

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

ans = float("inf")
for i in range(N):
    count = 0
    while A[i] % 2 == 0:
        A[i] //= 2
        count += 1
    ans = min(ans, count)
print(ans)

Submission status: Accepted

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


def judge_hasOdd(A):
    hasOdd = False
    for a in A:
        if a % 2 == 0:
            continue
        else:
            hasOdd = True
            break
    return hasOdd


count = 0
while True:
    if judge_hasOdd(A) == False:
        A = list(map(lambda x: x/2, A))
        count += 1
    else:
        break

print(count)

Submission status: Accepted

Solution code:
def main():
    n = int(input())
    a_list = list(map(int, input().split()))

    # temp_list = []
    count = 0
    is_ongoing = True
    while is_ongoing:
        for i, a in enumerate(a_list):
            if a % 2 == 0:
                # temp_list.append(a/2)
                a_list[i] /= 2
            else:
                is_ongoing = False
                print(count)
                break
        else:
            count += 1
        # a_list = temp_list[:]


if __name__ == '__main__':
    main()

Submission status: Accepted

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

count = 0

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

print(count)

Submission status: Accepted

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

print(count)

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

Solution code:
N = int(input())
nums = list(map(int, input().split()))
ans = 10**9
for i in nums:
    counter = 0 
    while i % 2 == 0:
        i /=2
        counter +=1
    if counter < ans:
        ans = counter
print(ans)

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!

# 3問目

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

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

    if hantei:
        count += 1
    else:
        break

print(count)

Submission status: Accepted

Solution code:
# coding: utf-8

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


for i in range(200):
    hantei = True
    
    for i in range(n):
        if a[i] % 2 == 0:
            a[i] = a[i] / 2
        else :
            hantei = False
            break

    if hantei:
        count += 1
    else:
        break


print(count)

Submission status: Accepted

Solution code:
import numpy as np

def how_many_times_divisibles(j):
	counter=0
	while j%2==0:
		j/=2
		counter+=1
	return counter

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

Submission status: Accepted

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

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

print(count)

Submission status: Accepted

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

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

print(count)

Submission status: Accepted

Solution code:
def n2(a):
    return n2(a//2)+1 if a%2==0 else 0
N = int(input())
A = list(map(int, input().split()))
print(min(map(n2,A)))

Submission status: Accepted

Solution code:
def sep(c):
    count=0
    while c%2==0:
        c=c/2
        count+=1
    return count

n=int(input())
a=list(map(int,input().split()))
ans=sep(a[0])
for i in range(1,n):
    ans=min(ans,sep(a[i]))
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def resolve():
	n=int(input())
	a=list(map(int,input().split()))
	m=10**9
	for i in a:
		c=0
		n=i
		while n%2==0 and c<m:
			c+=1
			n//=2
		m=min(c,m)
	print(m)
resolve()

Submission status: Accepted

Solution code:
#2019/10/17
N, *A = map(int, open(0).read().split())
#print(N, A)

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(int,input().split()))
ans=0
while all(map(lambda x:x&1==0,a)):
    for i,e in enumerate(a):
        a[i]=e//2
    ans+=1
print(ans)

Submission status: Accepted

Solution code:
n=int(input())
a=list(map(int,input().split()))
x=[]
for i in range(n):
    for k in range(1,100):
        if a[i]%(2**k)!=0:
            x.append(k-1)
            break
print(min(x))

Submission status: Accepted

Solution code:
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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
counter = 0
judge = False
N = int(input())
a_list = input().split()

for i in range(N):
    a_list[i] = int(a_list[i])


while True:
    for i in range(N):
        if not a_list[i]/2 == int(a_list[i] / 2):
            judge = True
            break
        a_list[i] = a_list[i] / 2
    if judge == True:break
    counter += 1


print(counter)

Submission status: Accepted

Solution code:
N = int(input())
numlist = list(map(int,input().split()))
temp = 9999999999999
for i in numlist:
	sum = 0
	if i % 2 != 0:
		temp =0
		break
	else:
		while i % 2 ==0:
			i //= 2
			sum += 1
		if temp > sum :
			temp = sum
			
print(temp)

Submission status: Accepted

Solution code:
n=int(input())
a=[int(_) for _ in input().split()]
cnt=0
while True:
  for i in range(n):
    if a[i]%2==0:
      a[i]=a[i]//2
    else:
      print(cnt)
      exit()
  cnt+=1

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
N = int(input())
A = list(map(int, input().split()))
n = 0

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N=int(input())
li=list(map(int,input().split()))
count=[0 for n in range(N)]
for n in range(N):
  while li[n]%2==0:
    li[n]/=2
    count[n]+=1
ans=min(count)
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

ans = 0
flag = True

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

print(ans)

Submission status: Accepted

Solution code:
n = int(input())
a = list(map(int, input().split()))
import math
result = 10**9
for i in range(n):
  temp = -1
  while a[i] == math.floor(a[i]):
    a[i] = a[i]/2
    temp += 1
  result = min(temp, result)
print(result)

Submission status: Accepted

Solution code:
N = int(input())
A = map(int, input().split())
ans = float("inf")
for a in A:
  cnt = len(bin(a)) - bin(a).rfind("1") - 1
  ans = min(ans, cnt)
print(ans)