  implicit none
  
  integer::N
  integer,dimension(200)::a
  integer::s,t,i,j
  integer,parameter::nmax=1000

  read(*,*)n
  read(*,*)a(1:n)
!  write(*,*)a

  s=0
  t=0
  do i=1,nmax
     t=0
     do j=1,n
        if(mod(a(j),2)==0)t=t+1
     end do

     if(t==n)then
        s=s+1
        a(1:n)=a(1:n)/2
     else
        exit
     end if

  end do

  write(*,*)s

end program