#include <bits/stdc++.h>
using namespace std;
const int MOD = 1000000007;
const long long INF = 1000000007;
const long long INF2 = 1000000007LL * 1000000007LL;
const long double EPS = 1e-9;
const int SIZE = 100000;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n, k, t;
  cin >> n >> k;
  int i = 0;
  vector<int> v;
  for (; i < n; ++i) {
    cin >> t;
    if (t > k) {
      v.push_back(t);
      ++i;
      break;
    }
  }
  for (; i < n; ++i) {
    cin >> t;
    v.push_back(t);
  }
  while (!v.empty() && v.back() <= k) v.pop_back();
  cout << n - v.size();
  return 0;
}
