#include <bits/stdc++.h>
using namespace std;

int main() {
  int N, A;
  cin >> N;
  int ans = 10000;
  for (int i=0; i < N; i++) {
    cin >> A;
    ans = min(ans, __builtin_ctz(A));
  }
  cout << ans << endl;
}
