#include <bits/stdc++.h>
using namespace std;
using Graph = vector<vector<int>>;
void CINT() {}
template <class Head, class... Tail>
void CINT(Head &&head, Tail &&...tail) {
  cin >> head;
  CINT(move(tail)...);
}
void OUT() {}
template <class Head, class... Tail>
void OUT(Head &&head, Tail &&...tail) {
  cout << head << (sizeof...(tail) ? " " : "\n");
  OUT(move(tail)...);
}
template <typename TypeInt>
TypeInt GCD(TypeInt a, TypeInt b) {
  return a % b == 0 ? b : GCD(b, a % b);
}
template <typename TypeInt>
TypeInt LCM(TypeInt a, TypeInt b) {
  return a * b / GCD(a, b);
}
template <class T>
bool chmax(T &a, const T &b) {
  if (a < b) {
    a = b;
    return true;
  }
  return false;
}
template <class T>
bool chmin(T &a, const T &b) {
  if (b < a) {
    a = b;
    return true;
  }
  return false;
}
template <class T>
bool comp(T a, T b) {
  return abs(a) < abs(b);
}
void YES(bool f) { printf(f ? "YES\n" : "NO\n"); }
void Yes(bool f) { printf(f ? "Yes\n" : "No\n"); }
void Possible(bool f) { printf(f ? "Possible\n" : "Impossible\n"); }
void POSSIBLE(bool f) { printf(f ? "POSSIBLE\n" : "IMPOSSIBLE\n"); }
const int dx[8] = {1, 0, -1, 0, 1, -1, -1, 1};
const int dy[8] = {0, 1, 0, -1, 1, 1, -1, -1};
const int NMAX = 200;
const int INF = 1e9;
const int MOD = 1e9 + 7;
bool flag;
signed main() {
  int N;
  CINT(N);
  map<int, int> mp;
  mp[8] = 0;
  for (int i = 0; i < (int)(N); i++) {
    int a;
    CINT(a);
    if (1 <= a && a < 400)
      mp[0]++;
    else if (400 <= a && a < 800)
      mp[1]++;
    else if (800 <= a && a < 1200)
      mp[2]++;
    else if (1200 <= a && a < 1600)
      mp[3]++;
    else if (1600 <= a && a < 2000)
      mp[4]++;
    else if (2000 <= a && a < 2400)
      mp[5]++;
    else if (2400 <= a && a < 2800)
      mp[6]++;
    else if (2800 <= a && a < 3200)
      mp[7]++;
    else
      mp[8]++;
  }
  int nmax, nmin;
  if (mp[8] > 0) {
    nmin = mp.size() - 1;
    nmax = (int)mp.size() - 1 + mp[8];
    if (nmax > 8) nmax = 8;
  } else {
    nmin = nmax = (int)mp.size() - 1;
  }
  printf("%d %d\n", nmin, nmax);
  return 0;
}
