import std.stdio;
import std.string;
import std.algorithm;
import std.conv;

void main() {
  int N = readln.chomp.to!int;
  auto A = readln.chomp.split.map!(to!int);

  int ans = (1e9).to!int;

  foreach(a; A) {
    int tmp;
    while (a % 2 == 0 && a > 0) {
      tmp++;
      a /= 2;
    }

    ans = min(ans, tmp);
  }

  ans.writeln;
}