#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7, INF = 1 << 30;
const double EPS = 1e-12, PI = 3.1415926535897932384626;
const int MAX_N = 5001;
const long long LINF = 100000000000000000;
int main() {
  int N, t = 0;
  cin >> N;
  set<int> tr;
  for (int i = 0; i < N; i++) {
    int a;
    cin >> a;
    if (a / 400 >= 8)
      t++;
    else {
      tr.insert(a / 400);
    }
  }
  cout << max(int(tr.size()), t) << " " << min(8, int(tr.size()) + t) << endl;
  return 0;
}
