#include <bits/stdc++.h>
using namespace std;
const int N = 100008;
int a[N];
int b[N];
int main() {
  int n = 0;
  int x = 0;
  scanf("%d %d", &n, &x);
  for (int i = 1; i <= n; ++i) {
    scanf("%d", a + i);
  }
  for (int i = 1; i <= n; ++i) {
    scanf("%d", b + i);
  }
  sort(a + 1, a + n + 1);
  sort(b + 1, b + n + 1);
  int cnt = 0;
  int j = 1;
  for (int i = n; i > 0; --i) {
    while (j <= n && a[j] + b[i] < x) ++j;
    if (j <= n)
      ++cnt;
    else
      break;
    ++j;
  }
  printf("%d %d\n", 1, cnt);
  return 0;
}
