#include <bits/stdc++.h>
using namespace std;
int main() {
  long long N;
  cin >> N;
  vector<long long> a(N);
  for (long long i = (0); i < (long long)(N); i++) {
    cin >> a[i];
  }
  long long ans = 0;
  while (true) {
    for (long long j = (0); j < (long long)(N); j++) {
      if (a[j] % 2 == 0)
        a[j] /= 2;
      else if (a[j] % 2 != 0) {
        cout << ans << endl;
        return 0;
      }
    }
    ans++;
  }
}
