
import java.util.Scanner
object Main {

  def main(args: Array[String]){
    val sc = new Scanner(System.in)

    val t = sc.nextLine().toInt
    val A = sc.nextLine().split(" ").map(_.toInt)

    def two_index(n:Int): Int = {
      var idx = 0
      var num = n
      while (num % 2 == 0){
        num = num / 2
        idx = idx + 1
      }
      return idx
    }
    
    val two_index_obj = two_index _ 
    println(A.map(two_index_obj).min)
  }
}
