'use strict'

function main(input) {

    input = input.split(/\n|\s/).map(v => ~~v)
    const n = input[0]
    let nums = input.slice(1, input.length)

    let cnt = 0
    let odd = false
    while (!odd) {

        odd = false

        for (let i = 0; i < n; i++) {
            let tmp
            if (nums[i] % 2 > 0) {
                odd = true
                continue
            }
        }
        cnt += (!odd) ? 1 : 0

        nums = nums.map(v => v / 2)
    }

    console.log(cnt)

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