'use strict'

function main(input) {
  input = input
    .trim()
    .split(/\n|\s/)
    .map(Number)
  const n = input[0]
  let nums = input.slice(1)
  let count = 0
  while (true) {
    for (let i = 0; i < n; i++) {
      if (nums[i] % 2 > 0) {
        console.log(count)
        return
      }
    }
    nums = nums.map(v => v / 2)
    count++
  }
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'))
