import java.util.*;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int n = Integer.parseInt(sc.next());
    int[] A = new int[n];
    for (int i = 0; i < n; i++){
      A[i] = Integer.parseInt(sc.next());
    }
    int ans = Integer.MAX_VALUE;
    int count = 0;
    for (int a: A){
      count = 0;
      while ((a%2) == 0){
        count += 1;
        a /= 2;
      }
      ans = Math.min(ans,count);
    }
    System.out.println(ans);

  }
} import java.util.*; util.* java class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int n = Integer.parseInt(sc.next());
    int[] A = new int[n];
    for (int i = 0; i < n; i++){
      A[i] = Integer.parseInt(sc.next());
    }
    int ans = Integer.MAX_VALUE;
    int count = 0;
    for (int a: A){
      count = 0;
      while ((a%2) == 0){
        count += 1;
        a /= 2;
      }
      ans = Math.min(ans,count);
    }
    System.out.println(ans);

  }
} Main public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int n = Integer.parseInt(sc.next());
    int[] A = new int[n];
    for (int i = 0; i < n; i++){
      A[i] = Integer.parseInt(sc.next());
    }
    int ans = Integer.MAX_VALUE;
    int count = 0;
    for (int a: A){
      count = 0;
      while ((a%2) == 0){
        count += 1;
        a /= 2;
      }
      ans = Math.min(ans,count);
    }
    System.out.println(ans);

  } main {
    Scanner sc = new Scanner(System.in);
    int n = Integer.parseInt(sc.next());
    int[] A = new int[n];
    for (int i = 0; i < n; i++){
      A[i] = Integer.parseInt(sc.next());
    }
    int ans = Integer.MAX_VALUE;
    int count = 0;
    for (int a: A){
      count = 0;
      while ((a%2) == 0){
        count += 1;
        a /= 2;
      }
      ans = Math.min(ans,count);
    }
    System.out.println(ans);

  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = Integer.parseInt(sc.next()); n Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int[] A = new int[n]; A new int[n] n for (int i = 0; i < n; i++){
      A[i] = Integer.parseInt(sc.next());
    } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
      A[i] = Integer.parseInt(sc.next());
    } {
      A[i] = Integer.parseInt(sc.next());
    } A[i] = Integer.parseInt(sc.next()) A[i] A i Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int ans = Integer.MAX_VALUE; ans Integer.MAX_VALUE Integer Integer.MAX_VALUE int count = 0; count 0 for (int a: A){
      count = 0;
      while ((a%2) == 0){
        count += 1;
        a /= 2;
      }
      ans = Math.min(ans,count);
    } int a A {
      count = 0;
      while ((a%2) == 0){
        count += 1;
        a /= 2;
      }
      ans = Math.min(ans,count);
    } {
      count = 0;
      while ((a%2) == 0){
        count += 1;
        a /= 2;
      }
      ans = Math.min(ans,count);
    } count = 0 count 0 while ((a%2) == 0){
        count += 1;
        a /= 2;
      } (a%2) == 0 (a%2) a 2 0 {
        count += 1;
        a /= 2;
      } count += 1 count 1 a /= 2 a 2 ans = Math.min(ans,count) ans Math.min(ans,count) Math.min Math ans count System.out.println(ans) System.out.println System.out System System.out ans String[] args args
import java.util.*;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int n = Integer.parseInt(sc.next());
    int[] A = new int[n];
    for (int i = 0; i < n; i++){
      A[i] = Integer.parseInt(sc.next());
    }
    int ans = Integer.MAX_VALUE;
    int count = 0;
    for (int a: A){
      count = 0;
      while ((a%2) == 0){
        count += 1;
        a /= 2;
      }
      ans = Math.min(ans,count);
    }
    System.out.println(ans);

  }
}
