#include <bits/stdc++.h>
using namespace std;
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;
}
const int inf = 1e9 + 10;
const int mod = 1e9 + 7;
const long long llinf = 1e18;
int main() {
  int n, a, tmp, count = 0, k = 0;
  vector<bool> data(10, false);
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a;
    if (1 <= a && a < 400) {
      tmp = 0;
    }
    if (400 <= a && a < 800) {
      tmp = 1;
    }
    if (800 <= a && a < 1200) {
      tmp = 2;
    }
    if (1200 <= a && a < 1600) {
      tmp = 3;
    }
    if (1600 <= a && a < 2000) {
      tmp = 4;
    }
    if (2000 <= a && a < 2400) {
      tmp = 5;
    }
    if (2400 <= a && a < 2800) {
      tmp = 6;
    }
    if (2800 <= a && a < 3200) {
      tmp = 7;
    }
    if (3200 <= a) {
      k++;
      continue;
    }
    if (!data[tmp]) {
      count++;
      data[tmp] = true;
    }
  }
  int ans2;
  if (k >= 1 && count == 0) {
    ans2 = 1;
  } else {
    ans2 = count;
  }
  cout << ans2 << " " << min(count + k, 8) << endl;
}
