using System;

class Program
{
    static void Main()
    {
        string[] s = Console.ReadLine().Split();
        int n = int.Parse(s[0]);
        int l = int.Parse(s[1]);
        string[] s1 = Console.ReadLine().Split();
        int[] visine = new int[n];
        int r = 0;
        for (int i = 0; i < n; i++)
        {
            if(l< int.Parse(s1[i]))
            {
                r++;
            }
            else
            {
                break;
            }
        }
        r++;
        if (r == n +1)
        {
            Console.WriteLine(-1);
        }
        else
        {
            Console.WriteLine(r);

        }
    }
}