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