#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k, i, j, c = 0, d;
  cin >> n >> k;
  vector<int> a;
  for (i = 0; i < n; i++) {
    cin >> m;
    a.push_back(m);
  }
  for (i = 0; i < n; i++) {
    if (a[i] <= k) {
      c++;
    } else
      break;
  }
  for (j = n - 1; j >= 0; j--) {
    if (a[j] <= k) {
      c++;
    } else
      break;
  }
  i = i - 1;
  j = j + 1;
  d = j - i;
  if (d > 0)
    cout << c << endl;
  else {
    d = -d;
    cout << c - d - 1 << endl;
  }
  return 0;
}
