#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cout.tie(0);
  cin.tie(0);
  srand(time(NULL));
  int n, k;
  cin >> n >> k;
  vector<int> v(n);
  int l = 0, r = n;
  for (int i = 0; i < n; i++) {
    cin >> v[i];
  }
  for (int i = 0; i < n; i++) {
    if (v[i] > k) {
      l = i - 1;
      break;
    }
  }
  for (int i = n - 1; i >= 0; i--) {
    if (v[i] > k) {
      r = i;
      break;
    }
  }
  if (l == 0 && r == n) {
    cout << n;
  } else
    cout << n - r + l << endl;
}
