#include <bits/stdc++.h>
#pragma GCC optimize("O3,no-stack-protector")
#pragma GCC optimize("unroll-loops")
#pragma GCC target("avx")
using namespace std;
using Graph = vector<vector<int64_t>>;
const double pi = M_PI;
const int64_t MOD = 1000000007;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  vector<int> c(9);
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    int a;
    cin >> a;
    if (a <= 399) {
      c[0]++;
    } else if (a <= 799) {
      c[1]++;
    } else if (a <= 1199) {
      c[2]++;
    } else if (a <= 1599) {
      c[3]++;
    } else if (a <= 1999) {
      c[4]++;
    } else if (a <= 2399) {
      c[5]++;
    } else if (a <= 2799) {
      c[6]++;
    } else if (a <= 3199) {
      c[7]++;
    } else {
      c[8]++;
    }
  }
  int ansmin = 0, ansmax = 0;
  for (int i = 0; i < 8; i++) {
    if (c[i] != 0) {
      ansmin++;
    }
  }
  ansmax += ansmin;
  if (c[8] != 0) {
    ansmax += min({8 - ansmin, c[8], 8});
  }
  if (c[8] == n) {
    ansmin = 1;
  }
  cout << ansmin << ' ' << ansmax << endl;
  return 0;
}
