#include <bits/stdc++.h>
using namespace std;
const long long INF = 1e9 + 7;
const long long N = 100002;
long long iro[8], ziyu = 0, n, saisyo = 0;
int main() {
  cin >> n;
  for (long long i = (0); i < (8); ++i) iro[i] = 0;
  for (long long i = (0); i < (n); ++i) {
    long long a;
    cin >> a;
    if (a < 3200)
      iro[a / 400] = 1;
    else
      ziyu++;
  }
  for (long long i = (0); i < (8); ++i) {
    if (iro[i] == 1) {
      saisyo++;
    }
  }
  cout << saisyo << " " << min(saisyo + ziyu, 8ll) << endl;
  return 0;
}
