#include <bits/stdc++.h>
using namespace std;
int n;
char a[1010], b[1010];
int get1() {
  int ans = 0, i = 0, j = 0;
  while (i < n && j < n) {
    while (a[i] <= b[j] && i < n && j < n) i++, j++;
    if (i < n && j < n) j++, ans++;
  }
  return ans;
}
int get2() {
  int ans = 0, i = 0, j = 0;
  while (i < n && j < n) {
    while (a[i] < b[j] && i < n && j < n) ans++, i++, j++;
    if (i < n && j < n) j++;
  }
  return ans;
}
int main() {
  cin >> n >> a >> b;
  sort(a, a + n);
  sort(b, b + n);
  cout << get1() << endl;
  cout << get2() << endl;
  return 0;
}
