#include <bits/stdc++.h>
using namespace std;

int main()
{
	int n, l;
	cin >> n >> l;
	
	int h[n];
	int stop = 1;
	
	for (int i=0; i<n; i++)
	{
		cin >> h[i];
		if (h[i] > l) stop++;
		else break;
	}
	
	if (stop <= n)
		cout << stop;
	else
		cout << -1;

	return 0;
}