import java.util.*;
import java.io.*;
import java.math.*;
 
public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int ans = Integer.MAX_VALUE;
        for(int i = 0; i < n; i++){
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        }
        System.out.println(ans);
    }
}
  import java.util.*; util.* java import java.io.*; io.* java import java.math.*; math.* java public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int ans = Integer.MAX_VALUE;
        for(int i = 0; i < n; i++){
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        }
        System.out.println(ans);
    }
} Main public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int ans = Integer.MAX_VALUE;
        for(int i = 0; i < n; i++){
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        }
        System.out.println(ans);
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int ans = Integer.MAX_VALUE;
        for(int i = 0; i < n; i++){
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        }
        System.out.println(ans);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int ans = Integer.MAX_VALUE; ans Integer.MAX_VALUE Integer Integer.MAX_VALUE for(int i = 0; i < n; i++){
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        } {
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        } int tmp = 0; tmp 0 int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc while(a % 2 == 0){
                tmp++;
                a /= 2;
            } a % 2 == 0 a % 2 a 2 0 {
                tmp++;
                a /= 2;
            } tmp++ tmp a /= 2 a 2 ans = Math.min(ans,tmp) ans Math.min(ans,tmp) Math.min Math ans tmp System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int ans = Integer.MAX_VALUE;
        for(int i = 0; i < n; i++){
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        }
        System.out.println(ans);
    }
} public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int ans = Integer.MAX_VALUE;
        for(int i = 0; i < n; i++){
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        }
        System.out.println(ans);
    }
} Main
import java.util.*;
import java.io.*;
import java.math.*;
 
public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int ans = Integer.MAX_VALUE;
        for(int i = 0; i < n; i++){
            int tmp = 0;
            int a = sc.nextInt();
            while(a % 2 == 0){
                tmp++;
                a /= 2;
            }
            ans = Math.min(ans,tmp);
        }
        System.out.println(ans);
    }
}
 