#include <bits/stdc++.h>
using namespace std;
int main() {
  char sherlock[1001], Mon[1001];
  int n, i, j, maxi = 0, mini;
  cin >> n;
  for (i = 0; i < n; i++) {
    cin >> sherlock[i];
  }
  for (i = 0; i < n; i++) {
    cin >> Mon[i];
  }
  sort(sherlock, sherlock + n);
  sort(Mon, Mon + n);
  for (i = 0, j = 0; i < n && j < n;) {
    if (sherlock[i] < Mon[j]) {
      maxi++;
      i++;
      j++;
    } else {
      j++;
    }
  }
  mini = n;
  for (i = 0, j = 0; i < n && j < n;) {
    if (Mon[j] >= sherlock[i]) {
      mini--;
      i++;
      j++;
    } else {
      j++;
    }
  }
  cout << mini << endl;
  cout << maxi << endl;
  return 0;
}
