function main(input){
  var _input = input.split('\n')
  var N = parseInt(_input[0])
  var strArr = _input[1].split(' ')
  var numArr = []
  for (var i = 0; i < strArr.length; i++){
  	var num = parseInt(strArr[i])
    if (num % 2 === 1) {
    	console.log(0)
      	return
    }else numArr.push(num / 2)
  }
  
  var result = 1
  while (true) {
    for (var i = 0; i < numArr.length; i++){
      var num = numArr[i]
      if (num % 2 === 1) {
          console.log(result)
          return
      } else numArr[i] = num / 2
    }
    result++
  }
  
  
}

main(require("fs").readFileSync("/dev/stdin", "utf8"));