#include <bits/stdc++.h>
using namespace std;
typedef vector<vector<long long>> matrix;
template <class T>
bool chmax(T &a, const T &b) {
  if (a < b) {
    a = b;
    return 1;
  }
  return 0;
}
template <class T>
bool chmin(T &a, const T &b) {
  if (b < a) {
    a = b;
    return 1;
  }
  return 0;
}
long long llpow(long long e, long long x) {
  long long res = 1LL;
  while (x) {
    if (x & 1) res *= e;
    e *= e;
    x /= 2;
  }
  return res;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  long long N;
  cin >> N;
  vector<bool> rate(8, false);
  long long ex = 0, ans = 0;
  for (long long i = 0; i < (N); i++) {
    long long a;
    cin >> a;
    if (a < 400)
      rate[0] = true;
    else if (a < 800)
      rate[1] = true;
    else if (a < 1200)
      rate[2] = true;
    else if (a < 1600)
      rate[3] = true;
    else if (a < 2000)
      rate[4] = true;
    else if (a < 2400)
      rate[5] = true;
    else if (a < 2800)
      rate[6] = true;
    else if (a < 3200)
      rate[7] = true;
    else
      ex++;
  }
  for (bool x : rate) ans += x;
  cout << ans << " " << ans + ex << "\n";
}
