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

int main(){
  int N,ans = 30;
  cin >> N;
  for(int i = 0; i < N; i++){
  	int a,b = 0;
    cin >> a;
    while(a % 2 == 0){
    	b++;
        a = a / 2; 
    }
    ans = min(b,ans);
  }
  cout << ans << endl;
}  