import java.util.*;

class Main
{
	public static void main(String[] args)
	{
		Scanner sc = new Scanner(System.in);
		int n;
		n=sc.nextInt();
		int ans=Integer.numberOfTrailingZeros(sc.nextInt());
		for(int i=1;i<n;i++)
		{
			ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt()));
		}
		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;
		n=sc.nextInt();
		int ans=Integer.numberOfTrailingZeros(sc.nextInt());
		for(int i=1;i<n;i++)
		{
			ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt()));
		}
		System.out.println(ans);
	}
} Main public static void main(String[] args)
	{
		Scanner sc = new Scanner(System.in);
		int n;
		n=sc.nextInt();
		int ans=Integer.numberOfTrailingZeros(sc.nextInt());
		for(int i=1;i<n;i++)
		{
			ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt()));
		}
		System.out.println(ans);
	} main {
		Scanner sc = new Scanner(System.in);
		int n;
		n=sc.nextInt();
		int ans=Integer.numberOfTrailingZeros(sc.nextInt());
		for(int i=1;i<n;i++)
		{
			ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt()));
		}
		System.out.println(ans);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n; n n=sc.nextInt() n sc.nextInt() sc.nextInt sc int ans=Integer.numberOfTrailingZeros(sc.nextInt()); ans Integer.numberOfTrailingZeros(sc.nextInt()) Integer.numberOfTrailingZeros Integer sc.nextInt() sc.nextInt sc for(int i=1;i<n;i++)
		{
			ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt()));
		} int i=1; int i=1; i 1 i<n i n i++ i++ i {
			ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt()));
		} {
			ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt()));
		} ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt())) ans Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt())) Math.min Math ans Integer.numberOfTrailingZeros(sc.nextInt()) Integer.numberOfTrailingZeros Integer sc.nextInt() sc.nextInt sc 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;
		n=sc.nextInt();
		int ans=Integer.numberOfTrailingZeros(sc.nextInt());
		for(int i=1;i<n;i++)
		{
			ans=Math.min(ans,Integer.numberOfTrailingZeros(sc.nextInt()));
		}
		System.out.println(ans);
	}
}