program tenquestionthree
    implicit none
    integer n, i, x
    integer,allocatable,dimension(:) ::A
    x=30
    read(*,*) n
    allocate(A(n))
     do i=1,n
     read(*,*) A(i)
     end do
     do i=1,n
      do while ((mod(A(i),2**x)).ne.0)
      x=x-1
      end do
    end do
    write(*,*) x
end program
