function main(input) {
  var list = input[1].split(" ").map(v=>v-0);
  var ans = 1000;
  list.forEach(v=>{
    var cnt = 0;
    while(v%2==0){
      v/=2;
      cnt++;
    }
    ans = Math.min(ans,cnt);
  });
  console.log(ans);
    
}
main(require('fs').readFileSync('/dev/stdin', 'utf8').trim().split("\n"))