import java.util.Scanner;

public class Main{
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[] arg = new int[n];
        for(int i=0;i<n;i++){
            arg[i] = Integer.parseInt(sc.next());
        }
        int min = cnt(arg[0]);
        if(min>0){
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        }
        
        System.out.println(min);
    }
    private static int cnt(int a){
        int cnt = 0;
        while(a%2==0){
            cnt++;
            a=a/2;
        }
        return cnt;
    }
} import java.util.Scanner; Scanner java.util public class Main{
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[] arg = new int[n];
        for(int i=0;i<n;i++){
            arg[i] = Integer.parseInt(sc.next());
        }
        int min = cnt(arg[0]);
        if(min>0){
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        }
        
        System.out.println(min);
    }
    private static int cnt(int a){
        int cnt = 0;
        while(a%2==0){
            cnt++;
            a=a/2;
        }
        return cnt;
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[] arg = new int[n];
        for(int i=0;i<n;i++){
            arg[i] = Integer.parseInt(sc.next());
        }
        int min = cnt(arg[0]);
        if(min>0){
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        }
        
        System.out.println(min);
    } main {
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[] arg = new int[n];
        for(int i=0;i<n;i++){
            arg[i] = Integer.parseInt(sc.next());
        }
        int min = cnt(arg[0]);
        if(min>0){
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        }
        
        System.out.println(min);
    } 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[] arg = new int[n]; arg new int[n] n for(int i=0;i<n;i++){
            arg[i] = Integer.parseInt(sc.next());
        } int i=0; int i=0; i 0 i<n i n i++ i++ i {
            arg[i] = Integer.parseInt(sc.next());
        } {
            arg[i] = Integer.parseInt(sc.next());
        } arg[i] = Integer.parseInt(sc.next()) arg[i] arg i Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int min = cnt(arg[0]); min cnt(arg[0]) cnt arg[0] arg 0 if(min>0){
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        } min>0 min 0 {
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        } for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            } int i=1; int i=1; i 1 i<n i n i++ i++ i {
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            } {
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            } int tmp = cnt(arg[i]); tmp cnt(arg[i]) cnt arg[i] arg i if(tmp<min){
                    min = tmp;
                } tmp<min tmp min {
                    min = tmp;
                } min = tmp min tmp if(min==0){break;} min==0 min 0 {break;} break; System.out.println(min) System.out.println System.out System System.out min String[] args args private static int cnt(int a){
        int cnt = 0;
        while(a%2==0){
            cnt++;
            a=a/2;
        }
        return cnt;
    } cnt {
        int cnt = 0;
        while(a%2==0){
            cnt++;
            a=a/2;
        }
        return cnt;
    } int cnt = 0; cnt 0 while(a%2==0){
            cnt++;
            a=a/2;
        } a%2==0 a%2 a 2 0 {
            cnt++;
            a=a/2;
        } cnt++ cnt a=a/2 a a/2 a 2 return cnt; cnt int a a public class Main{
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[] arg = new int[n];
        for(int i=0;i<n;i++){
            arg[i] = Integer.parseInt(sc.next());
        }
        int min = cnt(arg[0]);
        if(min>0){
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        }
        
        System.out.println(min);
    }
    private static int cnt(int a){
        int cnt = 0;
        while(a%2==0){
            cnt++;
            a=a/2;
        }
        return cnt;
    }
} public class Main{
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[] arg = new int[n];
        for(int i=0;i<n;i++){
            arg[i] = Integer.parseInt(sc.next());
        }
        int min = cnt(arg[0]);
        if(min>0){
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        }
        
        System.out.println(min);
    }
    private static int cnt(int a){
        int cnt = 0;
        while(a%2==0){
            cnt++;
            a=a/2;
        }
        return cnt;
    }
} Main
import java.util.Scanner;

public class Main{
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[] arg = new int[n];
        for(int i=0;i<n;i++){
            arg[i] = Integer.parseInt(sc.next());
        }
        int min = cnt(arg[0]);
        if(min>0){
            for(int i=1;i<n;i++){
                int tmp = cnt(arg[i]);
                if(tmp<min){
                    min = tmp;
                }
                if(min==0){break;}
            }
        }
        
        System.out.println(min);
    }
    private static int cnt(int a){
        int cnt = 0;
        while(a%2==0){
            cnt++;
            a=a/2;
        }
        return cnt;
    }
}