open System

[<EntryPoint>]
let main argv =
  let n = Console.ReadLine() |> int in
  let xs = Console.ReadLine().Split(' ') |> Array.map int in
  let rec f x = if x % 2 = 1 then 0 else (1 + f (x / 2)) in
  xs
  |> Array.map f
  |> Array.min
  |> Console.WriteLine
  0
