1 2
9
 7 6
4 20 16 14 3 17 4
 1 1
1000000000
 4 2
45 44 35 38
 2 1
4 1000000000
 2 1
1 4
 100 10
246 286 693 607 87 612 909 312 621 37 801 558 504 914 416 762 187 974 976 123 635 488 416 659 988 998 93 662 92 749 889 78 214 786 735 625 921 372 713 617 975 119 402 411 878 138 548 905 802 762 940 336 529 373 745 835 805 880 816 94 166 114 475 699 974 462 61 337 555 805 968 815 392 746 591 558 740 380 668 29 881 151 387 986 174 923 541 520 998 947 535 651 103 584 664 854 180 852 726 93
 3 3
1 5 20
 2 2
7 14
 9 30111088
824713578 11195876 458715185 731769293 680826358 189542586 550198537 860586039 101083021
 5 1
23 8 83 26 18
 3 1
4 8 16
 50 100
74 55 33 5 83 24 75 59 30 36 13 4 62 28 96 17 6 35 45 53 33 11 37 93 34 79 61 72 13 31 44 75 7 3 63 46 18 16 44 89 62 25 32 12 38 55 75 56 61 82
 9 1
1 2 4 9 15 32 64 128 1024
 2 5
10 11
 3 1
1 3 6
 3 19905705
263637263 417905394 108361057
 4 1
88 55 14 39
 3 1
4 5 6
 1 1
4
 3 2
4 9 18
 2 2
3 6
 1 1
20
 2 60669400
95037700 337255240
 29 2
1 3 7 15 31 63 127 255 511 1023 2047 4095 8191 16383 32767 65535 131071 262143 524287 1048575 2097151 4194303 8388607 16777215 33554431 67108863 134217727 268435455 536870911
 5 1
100 200 400 1000 2000
 2 10
21 42
 5 3
6 6 6 13 27
 3 1
1 4 6
 2 1
3 6
 1 1
3
 2 2
2 8
 1 1000000000
1
 4 1
2 4 8 32
 4 28
34 1 86 90
 4 25
100 11 1 13
 3 6
13 26 52
 3 3
1 7 13
 3 1
2 3 6
 2 1
3 5
 2 1
2 3
 2 2
8 16
 10 295206008
67980321 440051990 883040288 135744260 96431758 242465794 576630162 972797687 356406646 547451696
 5 3
1024 4096 16384 65536 536870913
 1 4
9
 2 1
5 10
 2 1
1 1000000000
 3 165219745
737649884 652879952 506420386
 3 72014068
430005292 807436976 828082746
 3 1
3 6 9
 2 2
8 11
 5 2
86 81 53 25 18
 1 1
2
 2 1
4 8
 3 2
4 5 6

2 1 29 4 28 1 1 1 1 2 4 1 0 4 0 1 3 4 1 1 1 0 4 1 27 7 1 2 1 1 1 1 0 1 1 1 1 1 0 1 0 1 0 24 1 2 29 1 2 1 1 4 0 1 0
	import java.io.BufferedReader;
	import java.io.IOException;
	import java.io.InputStreamReader;
	import java.io.PrintWriter;
	import java.util.ArrayList;
	import java.util.Arrays;
	import java.util.Map.Entry;
	import java.util.PriorityQueue;
	import java.util.StringTokenizer;
	import java.util.*;
	
	
	   public  class Main {
	
	
	
		/*public static int ispr(int n)
	    	{
	    	//boolean[] isPrime = new boolean[n+1];
	        for (int i = 2; i <= n; i++) {
	            Prime[i] = true;
	        }
	
	        // mark non-primes <= n using Sieve of Eratosthenes
	        for (int factor = 2; factor*factor <= n; factor++) {
	
	            // if factor is prime, then mark multiples of factor as nonprime
	            // suffices to consider mutiples factor, factor+1, ...,  n/factor
	            if (Prime[factor]) {
	                for (int j = factor; factor*j <= n; j++) {
	                    Prime[factor*j] = false;
	                }
	            }	
	        }	
	        // count primes
	
	        /*int primes = 0;
	        for (int i = 2; i <= n; i++) {
	            if (isPrime	[i])System.out.println(i);
	
	
	        }*/
		// System.out.println("The number of primes <= " + n + " is " + primes);
		//return 0;
		// if(isPrime[n]==true)return 1; else return 0;
	
		//}
	
	
	
	
	
	
	
		public static long fact(long x)
		{
			if(x==0)return 1;
			else return x*fact(x-1);
		}
	
	
		public static long exp(long x, long n, long M)
		{
	
			if(n==0) return 1;
	
			else if(n%2==0) return exp((x*x)%M,n/2,M);
			else return (x*exp((x*x)%M,(n-1)/2,M))%M;
	
		}
	
		//fi
	
		static long fib(long n)
		{
			long F[][] = new long[][]{{1,1},{1,0}};
			if (n == 0)
				return 0;
			power(F, n-1);
	
			return F[0][0];
		}
	
		static int mod=1000000007;
		
		static void multiply(long F[][], long M[][])
		{
			long x =  (((F[0][0]%mod)*(M[0][0]%mod))%mod + ((F[0][1]%mod)*(M[1][0]%mod))%mod)%mod;
			long y =  (((F[0][0]%mod)*(M[0][1]%mod))%mod + ((F[0][1]%mod)*(M[1][1]%mod))%mod)%mod;
			long z =  (((F[1][0]%mod)*(M[0][0]%mod))%mod + ((F[1][1]%mod)*(M[1][0]%mod))%mod)%mod;
			long w =  (((F[1][0]%mod)*(M[0][1]%mod))%mod + ((F[1][1]%mod)*(M[1][1]%mod))%mod)%mod;
	
			F[0][0] = x;
			F[0][1] = y;
			F[1][0] = z;
			F[1][1] = w;
		}
	
		/* Optimized version of power() in method 4 */
		static void power(long F[][], long n)				
		{
			if( n == 0 || n == 1)
				return;
			long M[][] = new long[][]{{1,1},{1,0}};
	
			power(F, n/2);
			multiply(F, F);
	
			if (n%2 != 0)
				multiply(F, M);
		}
	
	
	
	
		public static int gcd(int a, int b)
		{
			if(b==0)
				return a;
			else return gcd(b,a%b);
		}
	
		static  class MyScanner {
	
			BufferedReader br;
			StringTokenizer st;
	
			public MyScanner() {
				br = new BufferedReader(new InputStreamReader(System.in));
			}
	
			String next() {
				while (st == null || !st.hasMoreElements()) {
					try {
						st = new StringTokenizer(br.readLine());
					} catch (IOException e) {
						e.printStackTrace();
					}
				}
				return st.nextToken();
			}
	
			int nextInt() {
				return Integer.parseInt(next());
			}
	
			long nextLong() {
				return Long.parseLong(next());
			}
	
			double nextDouble() {
				return Double.parseDouble(next());
			}
	
			String nextLine(){
				String str = "";
				try {
					str = br.readLine();
				} catch (IOException e) {
					e.printStackTrace();
				}
				return str;
			}
	
		}
	
		static MyScanner sc = new  MyScanner();
		static PrintWriter pw = new PrintWriter(System.out, true);
		
	
		
		static void printPath(int parent[], int j)
		{
		    // Base Case : If j is source
		    if (parent[j]==-1)
		        {pw.print(j+" ");return;}
	
		    printPath(parent, parent[j]);
	
		    pw.print(j+" ");
		}
		
		
		//Main begins here :)
	/*	
		public static class Pair{
		    int a;
		    int b;
		    Pair(int p,int q){
		        a=p;
		        b=q;
		    }
		    public boolean equals(Object o) {
		        if (o instanceof Pair) {
		            Pair p = (Pair)o;
		            return p.a == a && p.b == b;
		        }
		        return false;
		    }
		    public int hashCode() {
		        return new Integer(a).hashCode() * 31 + new Integer(b).hashCode();
		    }
		}
		*/
	
	
	
		
		public static int max1(String st, int k)
		{
			int n1=0;
			int max=Integer.MIN_VALUE;
			int n = st.length();
			if(n==1)
			{
				if(st.charAt(0)=='1')return 1;
				else return 0;
			}
			
			for(int i=1;i<=k;i++)
			{
				int chp=i-1;
				
				if(st.charAt(chp)=='1')n1++;
				
			}
			max=Math.max(max, n1);
		//	if(k>=n)return max;
			int slides=n-k;
			int ptr1=0, ptr2=k-1;
			
			for(int i=1;i<=slides;i++)
			{
				//pw.println(st.substring(ptr1+i, ptr2+i+1));
				ptr1++; ptr2++;
				if(st.charAt(ptr1-1)=='1')n1--;
				if(st.charAt(ptr2)=='1')n1++;
				//pw.println("m1- "+n1);pw
				
				if(n1>max)max=n1;
				if(max==k){return k;}
			}
			
			return max;
			
		}
			
		
		public static String shift(String A)
		{
			char lc = A.charAt(A.length()-1);
			return lc+A.substring(0,A.length()-1);
			
		}
		
	
		
		
		static  class Point 
		{
			long x,y;
	
			public Point(long a, long b)
			{
				x=a;
				y=b;
			}

			public int compareTo(Point o) {
				// TODO Auto-generated method stub
				return Long.compare(this.x, o.x);
				
			}

			
			
	
		}
	
		static class compx implements Comparator<Point>
		{
			public int compare(Point a, Point b)
			{
	
				if(a.x>b.x)return 1;
				if(a.x<b.x) return -1;
					
				return 0;
			}
		}
		
		static class compy implements Comparator<Point>
		{
			public int compare(Point a, Point b)
			{
	
				if(a.y>b.y)return 1;
				if(a.y<b.y) return -1;
					
				return 0;
			}
		}
	
		
		public static int lucky(long y)
		{
			
			long d = y;
			int flg=0;
			//long nd = (long)Math.floor(Math.log10((double)y));
			//pw.println(nd);
			for(;d>=1;d=d/10)
			{
				long dg = d%10;
				if(dg!=0)flg++;
				if(flg==2)return 0;
					
			}
			return 1;
			
		}
		
		public static int diff(Time n, Time k)
		{
			
			int hn=n.h,mn=n.m,sn=n.s;
			int hk=k.h,mk=k.m,sk=k.s;
			
			
			int tc=0,cs=0,cm=0,ch=0;
			if(sk>sn)
			{
				int o1 = sk-sn;
				int o2 = sn+60-sk;
				
				if(o1>o2)
				{ 
					cs=o2;
					mn--;
				}
				if(o2>o1)
				{
					cs=o1;
				}
				if(o1==o2)
				{
				
					int min1 = Math.min(Math.abs(mk-mn), 60 - Math.abs(mk-mn));
					int mn2 = mn-1;
					int min2  = Math.min(Math.abs(mk-mn2), 60 - Math.abs(mk-mn2));
					if(min2<min1)
					{
						cs=o2;
						mn--;
					}
					else
					{
						cs=o1;
					}
					
				}
			}
			
			if(sk<sn)
			{
				int o1 = sn-sk;
				int o2 = sk+60-sn;
				
				if(o1>o2)
				{ 
					cs=o2;
					mn++;
				}
				if(o2>o1)
				{
					cs=o1;
				}
				if(o1==o2)
				{
				
					int min1 = Math.min(Math.abs(mk-mn), 60 - Math.abs(mk-mn));
					int mn2 = mn+1;
					int min2  = Math.min(Math.abs(mk-mn2), 60 - Math.abs(mk-mn2));
					if(min2<min1)
					{
						cs=o2;
						mn++;
					}
					else
					{
						cs=o1;
					}
					
				}
			}
			
			if(mk>mn)
			{
				int o1 = mk-mn;
				int o2 = mn+60-mk;
				
				if(o1>o2)
				{ 
					cm=o2;
					hn--;
				}
				if(o2>o1)
				{
					cm=o1;
				}
				if(o1==o2)
				{
					int min1 = Math.min(Math.abs(hk-hn), 24 - Math.abs(hk-hn));
					int hn2 = hn-1;
					int min2  = Math.min(Math.abs(hk-hn2), 24 - Math.abs(hk-hn2));
					if(min2<min1)
					{
						cm=o2;
						hn--;
					}
					else
					{
						cm=o1;
					}
				}
			}
			
			if(mk<mn)
			{
				int o1 = mn-mk;
				int o2 = mk+60-mn;
				
				if(o1>o2)
				{ 
					cm=o2;
					hn++;
				}
				if(o2>o1)
				{
					cm=o1;
				}
				if(o1==o2)
				{
					int min1 = Math.min(Math.abs(hk-hn), 24 - Math.abs(hk-hn));
					int hn2 = hn+1;
					int min2  = Math.min(Math.abs(hk-hn2), 24 - Math.abs(hk-hn2));
					if(min2<min1)
					{
						cm=o2;
						hn++;
					}
					else
					{
						cm=o1;
					}
				}
			}
			
			ch = Math.min(Math.abs(hk-hn), 24 - Math.abs(hk-hn));
			tc=cs+cm+ch;
			return tc;
			
			
			
			//return 3;
		}
		
		
		
		public static class Time
		{
			int h,m,s;
			
			public Time(int x, int y, int z)
			{
				h=x; m=y; s=z;
				
			}
			
		}
		
		static class Pair
		{
		    int x;
		    int y;
		    
		    public Pair(int a , int b)
		    {
		        x=a;
		        y=b;
		    }
		    
		    
		}
		
		static class comp implements Comparator<Pair>
		{
		    
		    @Override
		    
		    public int compare(Pair a ,Pair b)
		    {
		        if(b.x>a.x)return -1;
		        if(b.x<a.x)return 1;
		        return 0;
		        
		    }
		    
		}
		static class compv implements Comparator<Vouch>
		{
		    
		    @Override
		    
		    public int compare(Vouch a ,Vouch b)
		    {
		        if(b.c>a.c)return -1;
		        if(b.c<a.c)return 1;
		        return 0;
		        
		    }
		    
		}
			
		static class Vouch
		{
		   int l,r, c; 
		   
		    
		    public Vouch(int a ,int b, int ci)
		    {
		        l=a;
		        r=b;
		        c=ci;
		        
		    }
		    
		}
			
		
	
		
		
		public static int strStr(final String haystack, final String needle) {
			
			
			if(needle.equals("")) return -1;
		    if(haystack.equals("")&&needle.equals(""))return -1;
		
		    String temp="";
		    
		    int hl = haystack.length();
		    int nl = needle.length();
		    if(nl>hl) return -1;
		    int ret=-1;
	        String wind = haystack.substring(0,nl);
	        pw.println(wind);
	        if(wind.equals(needle)) return 0;
	        
	        for(int i=1;i<hl-nl;i++)
	        {
	            wind = wind.substring(1, wind.length());
	           
	            wind = wind+haystack.charAt(i+nl);
	            
	            pw.println(i+" "+wind);
	            if(wind.equals(needle)) 
	            {
	                ret=i; break;
	            }
	            
	        }
	        
	        return (ret==-1)?-1:ret;
	        
			    
			    
			}
		
		
		public static int diff(String a, String b)
		{
			int ret=0;
			for(int i=0;i<a.length();i++)
			{
				if(a.charAt(i)!=b.charAt(i))ret++;
			}
			return ret;
		}
		
		public static boolean inter(Vouch a, Vouch b)
		{
			//return true if there's intersection
			int s1 = a.l;
			int e1 = a.r;
			
			int s2 = b.l;
			int e2 = b.r;
			
			if(s1<s2)
			{
				if(e1>=s2)return true;
				else return false;
			}
			else if(s1>s2)
			{
				if(e2>=s1) return true;
				else return false;
			}
			else
			{
				return true;
			}
			
		
		}
		
		static class Com implements Comparator<Range>
		{
		    public int compare(Range a, Range b)
		    {
		         int ac=a.x; int bc=b.x;
		         if(ac>bc)return 1;
		          if(ac<bc)return -1;
		          return 0;
		         
		         
		    }
		     
		}
		static class Range
		{
		    int x,y,z;
		    
		    public Range(int a, int b,int c)
		    {
		        x=a;
		        y=b;
		        z=c;
		    }
		    
		}
		
		//static ArrayList<Integer> pr;
		public static void main(String[] args) {
	
          int n = sc.nextInt();
          int k = sc.nextInt();
          
          int arr[] = new int[n];
          
          for(int i=0;i<n;i++)arr[i]=sc.nextInt();
          
          Arrays.sort(arr);
          
          int max=arr[n-1];
          int req = max/2;
          int ans=0;
          int curr=2*k;
          for(int i=0;i<n&&curr<max;i++)
          {
               int ai = arr[i];
               if(ai<=curr)
               {
                    
                    curr=Math.max(curr,2*ai);
                         
               }
               else
               {
                   curr=2*curr;
                   ans++;
               }
               
          }
          pw.println(ans);
          
          
          
          
          
          
      
          	/*
	     String st = sc.nextLine();
	     
	     Stack<Character> stk = new Stack<Character>();
	     stk.push(st.charAt(0));
	     for(int i=1;i<st.length();i++)
	     {
	                    
	                    
	                    
	                    
	                    char cc = st.charAt(i);
	                    
	                    if(stk.isEmpty())
	                    {
	                       stk.push(cc);  
	                    }
	               else
	               {
	                    
	                    if(cc=='('||cc=='{'||cc=='[') stk.push(cc);  
	                    
	                    
	                    
	                    
	                    
	                    char pr = stk.peek();
	                    if(cc==')')
	                    {
	                         if(pr=='(')stk.pop();
	                         else stk.push(cc);
	                         
	                    }
	         
	          if(cc=='}')
	                    {
	                         if(pr=='{')stk.pop();
	                         else stk.push(cc);
	                         
	                    }
	                    
	                     if(cc==']')
	                    {
	                         if(pr=='[')stk.pop();
	                         else stk.push(cc);
	                         
	                    }
	               }
	          
	     }
	     if(stk.isEmpty())pw.println("B");
	     else pw.println("NB");
	     
	     while(!stk.isEmpty())pw.println(stk.pop());
	     */
	     
	     
		/*	
		int[] D = {4, 7, 4, 8, 4, 1}; 
        int[] arr = {2,4,5,5,6,9,11,11,13};
        
        int l=0;
        int r =arr.length-1;
        int sr=12;
        int mid=0;
        int flg=0;
        while(l<=r)
        {
             mid=(l+r)/2;
             if(arr[mid]>sr)r=mid-1;
              if(arr[mid]<sr)l=mid+1;
               if(arr[mid]==sr)
               {
                    flg=1;
                    break;
               }
             
             
             
        }
       */
        //pw.println(l+" "+r);
        
        /*
          int[] ar= {2,1,5,3,4,8,7};
          Stack<Integer> st =new  Stack<Integer>();
          
          for(int i=0;i<ar.length-1;i++)
          {
               if(st.isEmpty())
               {
                   st.push(ar[i]); 
                    
               }
               else
               {
                    while(!st.isEmpty()&&st.peek()<ar[i])
                    {
                         int g=st.pop();
                         pw.println(g+"--< "+ar[i]);
                       if(ar[i]==8)
                       {
                            pw.println(g);
                       }
                    }
                    st.push(ar[i]);
                    
               }
               
          }
        
        while(!st.isEmpty())
        {
            pw.println(st.pop()+"--< -1");  
             
        }
        */
       /* int x,y;
        x=sc.nextInt();
        y=sc.nextInt();
        
        int[][] arr = new int[x][y];
        
        
        for(int i=0;i<x;i++)
        {
             for(int j=0;j<y;j++)
             {
                  arr[i][j]=sc.nextInt();
             }
        }
        
        
        PriorityQueue<Range> q = new PriorityQueue<Range>(new Com());
        
        for(int i=0;i<x;i++)
        {
             q.add(new Range(arr[i][0],i,0));
        }
        
        for(int i=0;i<x*y;i++)
        {
             Range p = q.poll();
             int ari = p.y;
               int oi = p.z;
             pw.println(p.x);
             
             if(arr[ari].length-1==oi)
             {
                  q.add(new Range(Integer.MAX_VALUE,-1,-1));
             }
             else 
             {
                  q.add(new Range(arr[ari][oi+1],ari,oi+1));
             }
             
        }
        
        */
        
         /* int[] P = {3, 5, 3, 8, 3, 6}; 
		
		int n = D.length;
		int pt = P[0];
	
		int st=0;
		int fst=st;
		int i=0;
		while(true)
		{
		    pw.println("st "+st+" i- "+i);
		     if(D[i]<=pt)
		     {
		          pt=pt-D[i]+P[(i+1)%6];
		          //i++;
		          i=(i+1)%6;
		          if(i==st)
		          {
		               pw.println("path from "+st);
		               break;
		          }
		     }
		     else
		     {
		          st=(i+1)%6;
		         i=st;
		         if(st==0)
		         {
		              pw.println("No path");
		              break;
		         }
		          pt=P[i];
		          
		          
		     }
		}
		*/	
			
			
			
			
			
			    pw.close();
			    
		}
	
	
		
		
		
		
		
		
		
		
		
		
		
		
		
		
		
	} 