#include <bits/stdc++.h>
using namespace std;
long n, x, ans, q;
long ar1[200000], ar2[200000];
int main() {
  ios_base::sync_with_stdio(0);
  cin >> n >> x;
  for (int i = 1; i <= n; i++) cin >> ar1[i - 1];
  for (int i = 1; i <= n; i++) cin >> ar2[i - 1];
  sort(ar1, ar1 + n);
  sort(ar2, ar2 + n);
  q = n - 1;
  for (int i = 0; i < n; i++) {
    if (ar1[q] + ar2[i] >= x) {
      ++ans;
      --q;
    }
  }
  cout << 1 << " " << ans << endl;
  cin.get();
  cin.get();
  return 0;
}
