#include <bits/stdc++.h>
using namespace std;
int i, j;
int main() {
  int n;
  cin >> n;
  string s1, s2;
  cin >> s1 >> s2;
  sort(s1.begin(), s1.end());
  sort(s2.begin(), s2.end());
  int r = n - 1, ans = n;
  for (i = n - 1; i >= 0; i--) {
    if (s2[r] >= s1[i]) {
      r--;
      ans--;
    }
  }
  cout << ans << '\n';
  r = n - 1, ans = 0;
  for (i = n - 1; i >= 0; i--) {
    if (s2[r] > s1[i]) {
      r--;
      ans++;
    }
  }
  cout << ans << '\n';
}
