#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
const ll INF = 1000000000;
const ld PI = (acos(-1));
using Graph = vector<vector<int>>;
template <class T>
inline bool chmin(T& a, T b) {
  if (a > b) {
    a = b;
    return true;
  }
  return false;
}
template <class T>
inline bool chmax(T& a, T b) {
  if (a < b) {
    a = b;
    return true;
  }
  return false;
}
double rad(double a) { return a * 180 / PI; }
struct UnionFind {
  vector<int> par;
  UnionFind(int N) : par(N) {
    for (int i = 0; i < N; i++) par[i] = i;
  }
  int root(int x) {
    if (par[x] == x) return x;
    return par[x] = root(par[x]);
  }
  void unite(int x, int y) {
    int rx = root(x);
    int ry = root(y);
    if (rx == ry) return;
    par[rx] = ry;
  }
  bool same(int x, int y) {
    int rx = root(x);
    int ry = root(y);
    return rx == ry;
  }
};
int dp[100050];
int main() {
  int N;
  cin >> N;
  vector<int> a(N);
  for (int i = 0; i < (N); i++) cin >> a.at(i);
  vector<bool> ans(8, false);
  int cnt = 0;
  for (int i = 0; i < (N); i++) {
    if (a.at(i) <= 399 && a.at(i) >= 1)
      ans.at(0) = true;
    else if (a.at(i) <= 799)
      ans.at(1) = true;
    else if (a.at(i) <= 1199)
      ans.at(2) = true;
    else if (a.at(i) <= 1599)
      ans.at(3) = true;
    else if (a.at(i) <= 1999)
      ans.at(4) = true;
    else if (a.at(i) <= 2399)
      ans.at(5) = true;
    else if (a.at(i) <= 2799)
      ans.at(6) = true;
    else if (a.at(i) <= 3199)
      ans.at(7) = true;
    else
      cnt++;
  }
  int A = 0;
  for (int i = 0; i < 8; i++) {
    if (ans.at(i)) A++;
  }
  cout << A << ' ' << A + cnt << endl;
  return 0;
}
