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: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
N = int(input())
counter = 0
arr = [int(i) for i in input().split(" ")]
flag = True
while 0 < len(arr):
    counter = counter + 1
    ret = []
    for i in range(len(arr)):
        tmp  = arr[i] >> 1
        if tmp % 2 == 1:
            pass
        else:
            ret.append(tmp)
    arr = ret

print(counter)

Submission status: Wrong Answer

Solution code:
N=int(input())
L=list(map(int,input().split()))
A=sum(L)
Ans=0
n=0
while n<1 : 
  if A%2==1:
    print(Ans)
    break
  else :
    A=A//2
    Ans=Ans+1

Submission status: Wrong Answer

Solution code:
N = int(input())
lst = [int(x) for x in input().split()]
i = 0
tmp = 0
while tmp > 0:
  tmp = sum([x%2 for x in lst])
  lst = [x/2 for x in lst]
  i += 1
print(i-1)

Submission status: Wrong Answer

Solution code:
N = int(input())
lst = input().split()
i = 0
tmp = 0
while tmp>0:
  tmp = sum([x%2 for x in lst])
  lst = [x/2 for x in lst]
  i += 1
print(i-1)

Submission status: Wrong Answer

Solution code:
import numpy as np

x = np.array(input().split(),dtype=np.int32)

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

Submission status: Wrong Answer

Solution code:
n = int(input())
a = list(map(int,input().split()))
b = 0
while True:
    
   for s in range(0,n+1):
       
        if(a[s]%2 != 0):
            break
        
        else: 
            for t in range(0,n+1):
                y = int(a[t])
                a[t] = y/2
                break
            b = b + 1
            break
   break
               
                
               
              
print(b)

Submission status: Wrong Answer

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

a = set(a)
cnt = 10
for i in a:
    c = 0
    while i%2 == 0:
        i /=2
        c +=1
    cnt = min(cnt,c)

print(cnt)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-

n = int(input())

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

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

print(ans)

Submission status: Wrong Answer

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

res = 0

for num in num_list:
  count = 0
  
  while(num % 2  == 0):
    num /= 2
    count += 1
  
  if count < res:
    res = count
    
print(res)

Submission status: Wrong Answer

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

res = 0

for num in num_list:
  count = 0
  
  while(num % 2  == 0):
    num /= 2
    count += 1
  
  if count > res:
    res = count
    
print(res)

Submission status: Wrong Answer

Solution code:
if __name__ == '__main__':
    N = int(input())
    A = list(map(int, input().split(' ')))
    print(N,A)
    count = 0
    while True:
        A_b = [x%2 == 0 for x in A]
        if not False in A_b:
            A = list(map(lambda x: x//2, A))
            count += 1
        else:
            print(count)
            break

Submission status: Wrong Answer

Solution code:
import numpy as np

length = int(input())
nums = np.array(list(map(int, input().split())), np.int64)
count = 0
total = nums.sum()
while total % 2 == 0:
    count += 1
    nums = nums // 2
    total = nums.sum()

print(count)

Submission status: Wrong Answer

Solution code:
import numpy as np

length = int(input())
nums = np.array(list(map(int, input().split())), np.int64)
count = 0
total = nums.sum()
while total % 2 == 0:
    count += 1
    nums = nums // 2
    print(nums)
    total = nums.sum()

print(count)

Submission status: Wrong Answer

Solution code:
import numpy as np

length = int(input())
nums = np.array(list(map(int, input().split())), np.int64)
count = 0
total = nums.sum()
while total % 2 == 0:
    count += 1
    nums = nums // 2
    print(nums)
    total = nums.sum()
    print(type(total))

print(count)

Submission status: Wrong Answer

Solution code:
import numpy as np

length = int(input())
nums = np.array(list(map(int, input().split())), np.int32)
count = 0
total = nums.sum()
while total % 2 == 0:
    count += 1
    nums = nums // 2
    total = nums.sum()

print(count)

Submission status: Wrong Answer

Solution code:
#coding:utf-8

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

cnt = 0

for i in range(N):
    if l[i] % 2 == 0:
            l[i] //= 2
    else:
        break
    cnt += 1

cnt -= 1
print(cnt)

Submission status: Wrong Answer

Solution code:
N = int(input())
a = [int(x) for x in input().split()]
b = 0
while len(list(filter(lambda i : i % 2 != 0, list(a)))) == 0 :
    a = list(map(lambda x: x/2, a))
    b += 1
b

Submission status: Wrong Answer

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

count = 0
end=False
while(True):
	div = []
	for i in num:
		if(i % 2 == 0):
			div.append(i/2)
		else:
			print(count)
			end = True
	if(end == True):
		break
	num = div
	count = count + 1

Submission status: Wrong Answer

Solution code:
n = input()
v = list(input().split())

cnt = 0
flg = True
while flg:
  for i in range(len(v)):
    if int(v[i]) %2 == 0:
      pass
    else:
      flg = False
    v[i] = int(v[i])/2
  cnt = cnt + 1

print(cnt)

Submission status: Wrong Answer

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

print(A)

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

print(count)

Submission status: Wrong Answer

Solution code:
n = int(input())
lis = list(map(int,input().split()))
x = 0
y = 0
while True:
  for i,v in enumerate(lis):
    j = v/2
    if j.is_integer():
      lis[i] = j
      x += 1
  y += 1
  if not x == n:
    break

print(y)

Submission status: Wrong Answer

Solution code:
n = int(input())
lis = list(map(int,input().split()))
x = 0
y = 0
while True:
  for i,v in enumerate(lis):
    j = v/2
    if j.is_integer():
      lis[i] = j
      print(lis)
      x += 1
  y += 1
  if not x == n:
    break

print(y)

Submission status: Wrong Answer

Solution code:
_ = input()
l = list(map(int,input().split()))
mn = 99999
for i in l:
  count = 0
  if i %2 ==0:
    count +=1
    i /= 2
  else:
    continue
  if mn > count:
    count = mn
print(count)

Submission status: Wrong Answer

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

count = 0

while sum(data) % 2 == 0:
    for i in range(len(data)):
        data[i] = data[i] / 2

    count += 1

print(count)

Submission status: Wrong Answer

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

count = 0

while sum(data) % 2 == 0:
    for i in range(len(data)):
        data[i] = data[i] / 2

    if sum(data) % 2 == 0:
        count += 1

print(count)

Submission status: Wrong Answer

Solution code:
n = input()
a = list(map(int, input().split(' ')))
cnt = 0
while sum(x%2==0 for x in a) == n:
        a = list(map(lambda x: x / 2 if x % 2 == 0 else x, a))
        cnt += 1
print(cnt)

Submission status: Wrong Answer

Solution code:
N = input()
data = list(map(lambda x :int(x),input().strip().split()))
data.sort()
tmp = data[0]
cnt =0
while tmp >=1:
    if sum(list(map(lambda x:x%(2**cnt), data))) >= 1:break
    tmp/=2
    cnt=+1
print(cnt)

Submission status: Wrong Answer

Solution code:
N = input()
data = list(map(lambda x :int(x),input().strip().split()))
data_2 = list(map(lambda x:x%2, data))
res = sum(data_2)
if res >=1:
  print(0)
else:
  data.sort()
  tmp = data[0]
  cnt =0
  while tmp >=1:
    tmp/=2
    cnt=+1
    if sum(list(map(lambda x:x%2**cnt, data_2))) >= 1:break
  print(cnt)

Submission status: Wrong Answer

Solution code:
N = input()
data = list(map(lambda x :int(x),input().strip().split()))
data_2 = list(map(lambda x:x%2, data))
res = sum(data_2)
if res >=1:
  print(0)
else:
  data.sort()
  tmp = data[0]
  cnt = 0
  while tmp>=1:
    tmp/=2
    cnt+=1
  print(cnt)

Submission status: Wrong Answer

Solution code:
N = input()
data = list(map(lambda x :int(x),input().strip().split()))
data_2 = list(map(lambda x:x%2, data))
res = sum(data_2)
if res >=1:
  print(0)
else:
  data.sort()
  tmp = data[0]
  cnt = 0
  while tmp!=1:
    tmp/=2
    cnt+=1
  print(cnt)

Submission status: Wrong Answer

Solution code:
import numpy as np
N = int(input())
A = np.array(list(map(int, input().split())))
A = A%2
count = 1

print(A)

while 1 not in A:
  A = A%2
  count = count + 1

print(count)

Submission status: Wrong Answer

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

ans=0
for i in range(30):
    a=[a[j]/2 for j in range(n)]
    ans+=1
    if not sum(a).is_integer():
        break

print(ans-1)

Submission status: Wrong Answer

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

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

    
print(A)

Submission status: Wrong Answer

Solution code:
def how_many_times_div(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_div, a))

print (n)
print (a)

Submission status: Wrong Answer

Solution code:
n = input()
a = list(map(int, input().split()))
b = 0
def hantei(a):
    b = list(map(lambda x: x % 2, a))
    c = 0
    for i in range(len(b)):
        if a[i] == "0":
            c += 0
        else:
            c += 1
    if b == 0:
        d = 0
    else:
        d = 1
    return d

while True:
    c = hantei(a)
    if c == 0:
        b += 1
    else:
        break

print(b)

Submission status: Wrong Answer

Solution code:
import numpy as np
a = int(input())
b = np.array(a)


while b%2 == 0:
  n=1
  print(n)
  n += 1
else:
  print(0)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
N = int(input())
A = list(map(int, input().split()))
ans = 0
flg = "True"

while flg == "True":
    ans = ans + 1
    for i in range(N):
        if A[i] % 2 == 0:
            A[i] = A[i] / 2
        else:
            flg = "False"

print(ans)

Submission status: Wrong Answer

Solution code:
cnt=0
b=1
N=int(input())
A=input().split()

A=[int(A[j]) for j in range(N)]

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

Submission status: Wrong Answer

Solution code:
N = int(input())
a = [int(x) for x in input().split()]
b = [int(y) for y in range(N)]
for i in range(N):
    while a[i]%2==0:
        b[i]=b[i]+1
        a[i]=a[i]//2
print(min(b))

Submission status: Wrong Answer

Solution code:
N = int(input())
a = [int(x) for x in input().split()]
k=0
for j in range(N):
    while a[j]%2==0:
        a[j]=a[j]/2
    k=k+1
print(j)

Submission status: Wrong Answer

Solution code:
from itertools import takewhile
from functools import reduce

data_num = int(input())
data_list = [bin(int(num)) for num in input().split(' ')]

combine_data = reduce(lambda x, y: x or y, data_list)

results = takewhile(lambda x: x == '0', combine_data[::-1])

print(len(list(results)))

Submission status: Wrong Answer

Solution code:
n=int(input())
a=list(map(int,input().split()))
s=0
cnt=0
while True:
    tmp=a.copy()
    for j in range(n):
        s+=tmp.pop()
    if s%n==0:
        a=[int(j/2) for j in a]
        cnt+=1
        tmp=a.copy()
        s=0
    else : break
print(cnt)

Submission status: Wrong Answer

Solution code:
n=int(input())
a=list(map(int,input().split()))
s=0
cnt=0
while True:
    tmp=a.copy()
    for j in range(n):
        s+=tmp.pop()
    if s%n==0:
        a=[int(int(j)/2) for j in a]
        cnt+=1
        tmp=a.copy()
        s=0
    else : break
print(cnt)

Submission status: Wrong Answer

Solution code:
N = int( input() )
A = input().split()
n = 0
for num in range( N - 1 ) :
    if int( A[ num ] ) % 2 != 0 :
         break
    else :
        for num in range( N - 1 ) :
            A[ num ]  = int( A[ num ] ) / 2
        n = n + 1
print( n )

Submission status: Wrong Answer

Solution code:
N = int( input() )
A = input().split()
n = 0
for num in range( N - 1 ) :
    if int( A[ num ] ) % 2 != 0 :
         break
    else :
         for num in range( N - 1 ) :
            A[ num ]  = int( A[ num ] ) / 2
            n = n + 1
print( n )

Submission status: Wrong Answer

Solution code:
N = int(input())
a_list = list(map(int, input().split(' ')))
i, j = divmod(sum(a_list), 2)
count = 0
while j != 1:
    count += 1
    i, j = divmod(i, 2)
print(count)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

count = 0
for i in a:
  c = 0
  while i != 0 and i % 2 == 0:
    i /= 2
    c += 1
  if c <= count:
    count = c
print(count)

Submission status: Wrong Answer

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

count = 0
for i in a:
  c = 0
  while i != 0 and i % 2 == 0:
    i /= 2
    c += 1
  if c >= count:
    count = c
print(count)

Submission status: Wrong Answer

Solution code:
N = int( input() )
list = [ int(x) for x in input().split() ]
print( list )
n = 0
while n <= N-1 :
    if list[ n ] % 2  == 0 :
        list[ n ] = int( list[ n ] / 2 )
        n = n + 1
    else :
        n = n + 1
print( list )

Submission status: Wrong Answer

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

z = 9

for i in range(n):
  m = a[i]
  cnt = 0

  if m % 2 == 0:
      while m % 2 == 0:
          m=m/2
          cnt += 1
  z = min(z,cnt)  

print(z)

Submission status: Wrong Answer

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

z = 9
for i in range(n):
  m = int(a[i])
  cnt = 0
  while m % 2 == 0:
    m = m / 2
    cnt += 1
  z = min(z,cnt)  

print(z)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

ans = 10^10

for i in num_list:
  div_num = 0
  while i % 2 == 0:
    i  //= 2
    div_num + 1  
    
  if ans > div_num:
    ans = div_num

print(ans)

Submission status: Wrong Answer

Solution code:
n=int(input())
data=list(map(int, input().split()))
for i in range( max(data)):
  data = list(filter(lambda x: x%2==0, map( lambda x: int(x / 2),  data)))
  if len(data) < n:
    print(i+1)
    break

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

print(lst)

Submission status: Wrong Answer

Solution code:
from math import *

N = int(raw_input())
A = map(int, raw_input().split())
print [len([j for j in A if j % 2**i == 0]) for i in range(int(log(max(A), 2))+2)].index(0)-1

Submission status: Wrong Answer

Solution code:
#081-B(自作)
N=int(input())
A=list(map(int,input().split()))
ans=1
flag=True
if flag==True:
    for i in range(N):
        if A[i]%2==0:
            A[i]=A[i]/2
        else:
            flag=False
            break
    ans+=1
else:
    ans-=1
        
print(ans)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-

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

count = 0
while(True):
	if sum(list(map(lambda x: x % 2, numbers))) == 0:
		numbers = list(map(lambda x: x / 2, numbers))
		count += 1
	else:
		break
print(count)

Submission status: Wrong Answer

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

print(n, a)

for i in range(n):

	a_joined = a_joined | a[i]

a_joined = a_joined & -(a_joined)
print(len(bin(a_joined)) - 3)

Submission status: Wrong Answer

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

for i in range(n):

	a_joined = a_joined | a[i]

print(len(bin(a_joined)) - 3)

Submission status: Wrong Answer

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

m = 500000000 #max divide
for i in range(len(values)):
	nowV = values[i]
	nm = 0
	for j in range(500000000):
		if nowV % 2 == 0:
			nm += 1
			nowV = nowV / 2
			m = min(m,n)
		else:
			break 
print(m)

Submission status: Wrong Answer

Solution code:

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

m = 500000000 #max divide
for i in range(len(values)):
	nowV = values[i]
	nm = 0
	for j in range(500000000):
		if nowV % 2 == 0:
			nm += 1
			nowV = nowV / 2
			m = min(m,n)
		else:
			break 
print(m)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
n=int(input())
m=list(map(int,input().split()))
t=1
ans=0
while t>0:
  for i in range(n):
    if m[i]%2>0:
      t=0
      break
    m[i]//=2
  ans+=1
print(ans)

Submission status: Wrong Answer

Solution code:
count = 0

def shift_only():
    n = int(input())
    numbers = [int(n.strip()) for n in input().split()]
    half_and_count(numbers)
    print(count)

def half_and_count(list):
    global count
    new_list = []
    for num in list :
        if num%2 == 0:
            new_list.append(num/2)
        else:
            return False
    count += 1
    half_and_count(new_list)

Submission status: Wrong Answer

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

ans = 10
for i in range(n):
    c = 0
    while A[i] %2 == 0:
        A[i] = A[i]//2
        c += 1
        
    ans = min(ans,c)
print(ans)

Submission status: Wrong Answer

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

count = 0
flag = True

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

print(count)

Submission status: Wrong Answer

Solution code:
# 080 B

N =int(input())
A =[int(j) for j in input().split()]
ans = 0
for i in range(8):
    cnt= 0
    for j in range(N):
        if A[j]%2 ==0:
            cnt+=1
            A[j]=A[j]/2 
    if cnt==len(A):
        ans+=1
print(ans)

Submission status: Wrong Answer

Solution code:
n = int(input())
a = sum(list(map(int,input().split())))
ans = 0
if a % 2 != 0:
    print("0")
else:
    while(a % 2 == 0):
        a /= 2
        ans += 1
    print(ans)

Submission status: Wrong Answer

Solution code:
n = int(input())
a = sum(list(map(int,input().split())))
ans = 0
if a % 2 != 0:
    print("0")
else:
 while(a % 2 == 0):
     a /= 2
     ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
N = int(input())
data = list(map(int,input().split()))
remain = [i%2 for i in data ]
res = 0
while max(remain) == 0 and min(data)>1:
    for i in range(N):
        remain[i] = data[i]%2
        data[i] = data[i]//2
    res += 1
print(res)

Submission status: Wrong Answer

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

j=0
l=0
for k in range(100):
    for i in range(int(A)):
        if isinstance(B[i]/2,int):
            j=j+1
    
    if j!=int(A):
        print(l)
        break
    l=l+1

Submission status: Wrong Answer

Solution code:
n=int(input())
a=list(map(int,input().split()))
for i in range(1,32):
  for j in a:
    if j%2==1:
      print(i-1)
      break
    else:
      j=j//2

Submission status: Wrong Answer

Solution code:
n = input()
x = [int(i) for i in input().split()]
min_n = 100
c = 0
for i in x:
    while i%2==0:
        i = i/2
        c+=1
    if c < min_n:
        min_n=c
        c=0
print(min_n)

Submission status: Wrong Answer

Solution code:
n = input()
x = [int(i) for i in input().split()]
print(x)
min_n = 100
c = 0
for i in x:
    while i%2==0:
        i = i/2
        c+=1
    if c < min_n:
        min_n=c
        c=0
print(min_n)

Submission status: Wrong Answer

Solution code:
a = list(map(int, input().split()))
def calc(a):
    return a /2
count = 0
for i in range(0, 99999999):
    if sum(a) % 2 == 0:
        count += 1
        a = list(map(calc,a))
    else:
        break
print(count)

Submission status: Wrong Answer

Solution code:
N = int(input())
A = list(map(int,input().split()))
def gcd(x,y):
    if x<y:
        z = x
        x = y
        y = z
    if y==0:
        return x
    return gcd(y, x%y)
for i in range(N):
    if i==0:
        all_gcd = gcd(A[i],A[i+1])
    else:
        all_gcd = gcd(all_gcd,A[i])
print(all_gcd)
for i in range(50):
    if all_gcd<2**i:
        print(i-1)
        break

Submission status: Wrong Answer

Solution code:
# https://qiita.com/_-_-_-_-_/items/34f933adc7be875e61d0
# abcde	s=input()	s='abcde'
# abcde	s=list(input())	s=['a', 'b', 'c', 'd', 'e']
# 5(1つだけ)	a=int(input())	a=5
# 1 2	| x,y = s_inpl()   |	x=1,y=2
# 1 2 3 4 5 ... n 　	li = input().split()	li=['1','2','3',...,'n']
# 1 2 3 4 5 ... n 　	li = inpl()	li=[1,2,3,4,5,...,n]
# FFFTFTTFF 　	li = input().split('T')	li=['FFF', 'F', '', 'FF']

# INPUT
# 3
# hoge
# foo
# bar
# ANSWER
# n=int(input())
# string_list=[input() for i in range(n)]

import math
import copy
from collections import defaultdict, Counter
from itertools import product
from bisect import bisect_left, bisect_right
import numpy as np

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

N = int(input())

A = np.array(inpl())

ans = 0
while True:
    A = A/2
    if sum(A) * 10 % 10 != 0:
        break
    ans += 1

print(ans)

Submission status: Wrong Answer

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

answer = 0

while True:
  if sum([a%2==0 for a in A])==0:
    answer +=1
    A = [a//2 for a in A]
  else:
    break

print(answer)

Submission status: Wrong Answer

Solution code:
a = int(input())
A = list(map(int,input().split() ) )
count = 0
flag = 0
while flag == 0 and count < 10^2:
    for i in range(len(A)):
        if A[i] %2 !=0 or A[i] == 0:
            flag = 1
    if flag == 0:        
        for i in range(len(A)):
            A[i] = int(A[i]/2)
        count += 1
print(count)

Submission status: Wrong Answer

Solution code:
a = int(input())
A = list(map(int,input().split() ) )
count = 0
flag = 0
while flag == 0 and count < 10^2:
    for i in range(len(A)):
        if A[i] %2 !=0:
            flag = 1
    if flag == 0:        
        for i in range(len(A)):
            A[i] = int(A[i]/2)
        count += 1
print(count)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
n=int(input())
lst=[int(i) for i in input().split()]
ans=[0]*n
for i in range(n):
  while lst[i]%2==0:
    lst[i]=lst[i]//2
print(min(lst))

Submission status: Wrong Answer

Solution code:
N=int(input())
lst=[int(i) for i in input().split()]
for i in range(N):
  if lst[i]%2==0:
    lst[i]=lst[i]//2
  else:
    lst[i]=0
print(min(lst))

Submission status: Wrong Answer

Solution code:
N=int(input())
lst=[int(i) for i in input().split()]
for i in range(N):
  lst[i]=lst[i]//2
print(min(lst))

Submission status: Wrong Answer

Solution code:
N = int(input())
A = [int(i) for i in input().split()]
M = 0
for i in range(N):
  count = 0
  while A[i] % 2 == 0:
    A[i] = A[i] //2
    count += 1
  M = max(M, count)
print(M)

Submission status: Wrong Answer

Solution code:
n = int(input())
lst = list(map(int, input().split()))
ans = 0
for x in lst:
  c = 0
  while x % 2 == 0:
    x //= 2
    c += 1
  if ans < c:
    ans = c
print(ans)

Submission status: Wrong Answer

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

for i in a:
    tmp = 0
    for j in range(1, 9):
        if i % 2 == 0:
            i /= (2)
            tmp += 1
        else:
            break
    arr.append(tmp)
print(min(arr))

Submission status: Wrong Answer

Solution code:
from math import log2 as log

n = int(input())
n_lst = list(map(int,input().split()))
ans = 0
while True:
    if sum(n_lst)%2 == 1:
        break
    else:
        for i in range(len(n_lst)):
            n_lst[i] //= 2
        ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
def count2(number):
    count = 0
    while True:
        if number % 2 == 0:
            count = count + 1
            number = number / 2
        else:
            break
    return count


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

answer = min(list(map(count2, A_list)))
    
print(answer)

Submission status: Wrong Answer

Solution code:
l = list(input().split(" "))

loop_count = 0
count = 0
min_count = 0

for n in l:
    loop_count = loop_count + 1
    while int(n) % 2 == 0:
        n = int(n)/2
        count = count + 1
    if loop_count == 1:
        min_count = count
    elif min_count > count:
        min_count = count
    count = 0

print(min_count)

Submission status: Wrong Answer

Solution code:
l = list(input().split(" "))

d = [0]
count = 0
max_count = 0

for n in l:
    while int(n) % 2 == 0:
        n = int(n)/2
        count = count + 1
    if max_count < count:
        max_count = count
    count = 0

print(max_count)

Submission status: Wrong Answer

Solution code:
l = list(input().split(","))

d = [0]
count = 0
max_count = 0

for n in l:
    while int(n) % 2 == 0:
        n = int(n)/2
        count = count + 1
    if max_count < count:
        max_count = count
    count = 0

print(max_count)

Submission status: Wrong Answer

Solution code:
N=int(input())
A=list(map(int, input().split()))
B=A[:]
i=0
while i < N:
    if A[i] % 2 == 0:
        A[i] = A[i]//2
        if i == N - 1:
            B = A[:]
            i = -1
        i += 1
    else:
        break
print(B)

Submission status: Wrong Answer

Solution code:
N=int(input())
A=list(map(int, input().split()))
B=A[:]
i=0
while i < N:
    if A[i] % 2 == 0:
        A[i] = A[i]//2
        print(A[i])
        if i == N - 1:
            B = A[:]
            i = -1
        i += 1
    else:
        break
print(B)

Submission status: Wrong Answer

Solution code:
N=int(input())
A=list(map(int, input().split()))
B=A[:]
i=0
while i < N:
    if A[i] % 2 == 0:
        A[i] = A[i]//2
        print(A[i])
        if i == N-1:
            B = A[:]
            i = -1
        i =+ 1
    else:
        break
print(B)

Submission status: Wrong Answer

Solution code:
 ### ABC081B - Shift only
n = int(input())
a = list(map(int, input().split()))
cnt_list = []

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

Submission status: Wrong Answer

Solution code:
 ### ABC081B - Shift only
n = int(input())
a = list(map(int, input().split()))
cnt_list = []

for i in range(n):
    countTemp = 0
    while a[i]%2 !=0:
        a[i] //= 2    
        countTemp =+ 1
    cnt_list.append(countTemp)
print(min(cnt_list))

Submission status: Wrong Answer

Solution code:
def check(a,cnt):
  b = [int(x)%2 for x in a]
  if 1 in b:
    return 0,cnt,a
  else :
    cnt +=1
    b = [int(x)/2 for x in a]
    return 1,cnt,b
 
N = input()
a = input().split()
cnt = 0
m = 1
while(m == 0):
  m,cnt,a = check(a,cnt)
  if m == 0:
    print(cnt)
  else :
    continue

Submission status: Wrong Answer

Solution code:
def check(a,cnt):
  b = [int(x)%2 for x in a]
  if 1 in b:
    return 0,cnt
  else :
    cnt +=1
    b = [int(x)/2 for x in a]
    return 1,cnt
 
N = input()
a = input().split()
cnt = 0
m = 1
while(m == 0):
  m,cnt = check(a,cnt)
  if m == 0:
    print(cnt)
  else :
    continue

Submission status: Wrong Answer

Solution code:
input()
val = sum(map(int, input().split()))
count = 0
while True:
    if val % 2 == 1:
        break
    val /= 2
    count += 1
print (count)

Submission status: Wrong Answer

Solution code:
import random
N = int(input())
A = random.sample(range(1000000), k=N)
c = 1000000
for i in range(len(A)):
    tmp = 0
    while A[i]%2 == 0:
        tmp+=1
        A[i] //= 2
    c = min(c,tmp)
print(c)

Submission status: Wrong Answer

Solution code:
N = input()
bb = [int(x) for x in input().split()]
cnt = 0
while True:
    c = [x%2 for x in bb]
    if c != [0, 0, 0]:
        break
    bb = [x/2 for x in bb]
    cnt += 1
print(cnt)