import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();

		int[] A = new int[N];

		int min = 0;

		for(int i=0; i<N; i++) {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		}

		int count = 0;
		for(int i=0; i<Math.log(min)/Math.log(2); i++) {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		}

		System.out.println(count);
	}

	public static void print(Object o) {
		System.out.print(o);
	}

	public static void println(Object o) {
		System.out.println(o);
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();

		int[] A = new int[N];

		int min = 0;

		for(int i=0; i<N; i++) {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		}

		int count = 0;
		for(int i=0; i<Math.log(min)/Math.log(2); i++) {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		}

		System.out.println(count);
	}

	public static void print(Object o) {
		System.out.print(o);
	}

	public static void println(Object o) {
		System.out.println(o);
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();

		int[] A = new int[N];

		int min = 0;

		for(int i=0; i<N; i++) {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		}

		int count = 0;
		for(int i=0; i<Math.log(min)/Math.log(2); i++) {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		}

		System.out.println(count);
	} main {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();

		int[] A = new int[N];

		int min = 0;

		for(int i=0; i<N; i++) {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		}

		int count = 0;
		for(int i=0; i<Math.log(min)/Math.log(2); i++) {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		}

		System.out.println(count);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int[] A = new int[N]; A new int[N] N int min = 0; min 0 for(int i=0; i<N; i++) {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		} {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		} A[i] = sc.nextInt() A[i] A i sc.nextInt() sc.nextInt sc min = i==0 || min > A[i] ? A[i] : min min i==0 || min > A[i] ? A[i] : min i==0 || min > A[i] i==0 i 0 min > A[i] min A[i] A i A[i] A i min int count = 0; count 0 for(int i=0; i<Math.log(min)/Math.log(2); i++) {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		} int i=0; int i=0; i 0 i<Math.log(min)/Math.log(2) i Math.log(min)/Math.log(2) Math.log(min) Math.log Math min Math.log(2) Math.log Math 2 i++ i++ i {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		} {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		} boolean flag = false; flag false for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			} int j=0; int j=0; j 0 j<N j N j++ j++ j {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			} {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			} if(A[j]%2 != 0) flag = true; A[j]%2 != 0 A[j]%2 A[j] A j 2 0 flag = true flag true A[j] = A[j]/2 A[j] A j A[j]/2 A[j] A j 2 if(flag) {
				break;
			}else {
				count++;
			} flag {
				break;
			} break; {
				count++;
			} count++ count System.out.println(count) System.out.println System.out System System.out count String[] args args public static void print(Object o) {
		System.out.print(o);
	} print {
		System.out.print(o);
	} System.out.print(o) System.out.print System.out System System.out o Object o o public static void println(Object o) {
		System.out.println(o);
	} println {
		System.out.println(o);
	} System.out.println(o) System.out.println System.out System System.out o Object o o public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();

		int[] A = new int[N];

		int min = 0;

		for(int i=0; i<N; i++) {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		}

		int count = 0;
		for(int i=0; i<Math.log(min)/Math.log(2); i++) {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		}

		System.out.println(count);
	}

	public static void print(Object o) {
		System.out.print(o);
	}

	public static void println(Object o) {
		System.out.println(o);
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();

		int[] A = new int[N];

		int min = 0;

		for(int i=0; i<N; i++) {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		}

		int count = 0;
		for(int i=0; i<Math.log(min)/Math.log(2); i++) {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		}

		System.out.println(count);
	}

	public static void print(Object o) {
		System.out.print(o);
	}

	public static void println(Object o) {
		System.out.println(o);
	}
} Main
import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();

		int[] A = new int[N];

		int min = 0;

		for(int i=0; i<N; i++) {
			A[i] = sc.nextInt();
			min = i==0 || min > A[i] ? A[i] : min;
		}

		int count = 0;
		for(int i=0; i<Math.log(min)/Math.log(2); i++) {
			boolean flag = false;
			for(int j=0; j<N; j++) {
				if(A[j]%2 != 0) flag = true;
				A[j] = A[j]/2;
			}
			if(flag) {
				break;
			}else {
				count++;
			}
		}

		System.out.println(count);
	}

	public static void print(Object o) {
		System.out.print(o);
	}

	public static void println(Object o) {
		System.out.println(o);
	}
}