#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k;
  cin >> n >> k;
  std::vector<int> a(n);
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  int buf = 0;
  for (int i = 0; i < n; i++) {
    if (a[i] <= k) {
      buf++;
      a[i] = 10000;
    } else {
      break;
    }
  }
  for (int i = n - 1; i >= 0; i--) {
    if (a[i] <= k && a[i] != -1) {
      buf++;
      a[i] = 10000;
    } else {
      break;
    }
  }
  cout << buf;
}
