#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<int> a(n);
  set<int> x;
  int num = 0;
  for (int i = 0; i < n; i++) {
    cin >> a.at(i);
    if (a.at(i) < 2800) {
      x.insert(a.at(i) / 400);
    } else {
      num++;
    }
  }
  int p = x.size();
  int q = min(p + num, 8);
  cout << p << " " << q << endl;
  return 0;
}
