#include <bits/stdc++.h>
#define ll long long

using namespace std;

int main(){
    ios_base::sync_with_stdio(0);cin.tie(0);
    ll n,l;
    cin>>n>>l;
    ll counter=1;
    for(ll i =0;i<n;i++){
        ll visina;
        cin>>visina;
        if(visina>l){
            counter++;
        }
        else{
            break;
        }
    }
    if(counter>n){
        counter=-1;
    }
    cout<<counter;
}