function Main(input) {
  input = input.split("\n");
  n = input[0].split("").map(Number);
  a = input[1].split(" ").map(Number);
  var odd = true;
  var ans = 0;
  while(odd){
    for(var i=0;i<n[0];i++){
      if(a[i]%2==0){
        a[i] = a[i]/2;
      }else{
        odd = false;
      }
    }
    if(odd){
      ans++;
    }
  }
  console.log(ans);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));