import java.util.Scanner;

class Main {
  public static void main(String[] args) {
    Scanner s = new Scanner(System.in);
    int n = s.nextInt();
    int min = Integer.MAX_VALUE;
    for (int i = 0; i < n; i++) {
      int num = s.nextInt();
      int cnt = count(num);
      if (cnt < min) min = cnt;
    }
    System.out.println(min);
  }

  private static int count(int num) {
    int cnt = 0;
    while (num > 0 && num % 2 == 0) {
      num /= 2;
      cnt++;
    }
    return cnt;
  }
} import java.util.Scanner; Scanner java.util class Main {
  public static void main(String[] args) {
    Scanner s = new Scanner(System.in);
    int n = s.nextInt();
    int min = Integer.MAX_VALUE;
    for (int i = 0; i < n; i++) {
      int num = s.nextInt();
      int cnt = count(num);
      if (cnt < min) min = cnt;
    }
    System.out.println(min);
  }

  private static int count(int num) {
    int cnt = 0;
    while (num > 0 && num % 2 == 0) {
      num /= 2;
      cnt++;
    }
    return cnt;
  }
} Main public static void main(String[] args) {
    Scanner s = new Scanner(System.in);
    int n = s.nextInt();
    int min = Integer.MAX_VALUE;
    for (int i = 0; i < n; i++) {
      int num = s.nextInt();
      int cnt = count(num);
      if (cnt < min) min = cnt;
    }
    System.out.println(min);
  } main {
    Scanner s = new Scanner(System.in);
    int n = s.nextInt();
    int min = Integer.MAX_VALUE;
    for (int i = 0; i < n; i++) {
      int num = s.nextInt();
      int cnt = count(num);
      if (cnt < min) min = cnt;
    }
    System.out.println(min);
  } Scanner s = new Scanner(System.in); s new Scanner(System.in) int n = s.nextInt(); n s.nextInt() s.nextInt s int min = Integer.MAX_VALUE; min Integer.MAX_VALUE Integer Integer.MAX_VALUE for (int i = 0; i < n; i++) {
      int num = s.nextInt();
      int cnt = count(num);
      if (cnt < min) min = cnt;
    } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
      int num = s.nextInt();
      int cnt = count(num);
      if (cnt < min) min = cnt;
    } {
      int num = s.nextInt();
      int cnt = count(num);
      if (cnt < min) min = cnt;
    } int num = s.nextInt(); num s.nextInt() s.nextInt s int cnt = count(num); cnt count(num) count num if (cnt < min) min = cnt; cnt < min cnt min min = cnt min cnt System.out.println(min) System.out.println System.out System System.out min String[] args args private static int count(int num) {
    int cnt = 0;
    while (num > 0 && num % 2 == 0) {
      num /= 2;
      cnt++;
    }
    return cnt;
  } count {
    int cnt = 0;
    while (num > 0 && num % 2 == 0) {
      num /= 2;
      cnt++;
    }
    return cnt;
  } int cnt = 0; cnt 0 while (num > 0 && num % 2 == 0) {
      num /= 2;
      cnt++;
    } num > 0 && num % 2 == 0 num > 0 num 0 num % 2 == 0 num % 2 num 2 0 {
      num /= 2;
      cnt++;
    } num /= 2 num 2 cnt++ cnt return cnt; cnt int num num
import java.util.Scanner;

class Main {
  public static void main(String[] args) {
    Scanner s = new Scanner(System.in);
    int n = s.nextInt();
    int min = Integer.MAX_VALUE;
    for (int i = 0; i < n; i++) {
      int num = s.nextInt();
      int cnt = count(num);
      if (cnt < min) min = cnt;
    }
    System.out.println(min);
  }

  private static int count(int num) {
    int cnt = 0;
    while (num > 0 && num % 2 == 0) {
      num /= 2;
      cnt++;
    }
    return cnt;
  }
}
