#include <bits/stdc++.h>
int main() {
  int i, n, k;
  scanf("%d %d", &n, &k);
  int a[n];
  int count = 0, j = 0;
  for (i = 0; i < n; i++) {
    scanf("%d", &a[i]);
  }
  for (i = 0; i < n; i++) {
    if (a[i] <= k)
      count++;
    else {
      j = 1;
      break;
    }
  }
  if (j != 0) {
    for (i = n - 1; i >= 0; i--) {
      if (a[i] <= k)
        count++;
      else
        break;
    }
  }
  printf("%d\n", count);
  return 0;
}
