#include <bits/stdc++.h>
const int INF = (int)1e9;
const long long MOD = (long long)1e9 + 7;
const long long LINF = (long long)1e18;
const double PI = acos(-1.0);
const double EPS = 1e-9;
using namespace ::std;
void solve() {
  int N;
  cin >> N;
  vector<int> A(100, 0);
  vector<int> iro(9, 0);
  A[0] = 399;
  A[1] = 799;
  A[2] = 1199;
  A[3] = 1599;
  A[4] = 1999;
  A[5] = 2399;
  A[6] = 2799;
  A[7] = 3199;
  for (int i = 0; i < N; ++i) {
    int R;
    cin >> R;
    for (int i = 0; i < 8; ++i) {
      if (R <= A[i]) {
        iro[i]++;
        break;
      }
    }
    if (R >= 3200) {
      iro[8]++;
    }
  }
  int ans = 0;
  for (int i = 0; i < 8; ++i) {
    if (iro[i]) {
      ++ans;
    }
  }
  int res = iro[8];
  if (ans == 0) {
    if (res) {
      cout << 1;
    } else {
      cout << 0;
    }
  } else {
    cout << ans;
  }
  cout << " " << min(9, ans + res) << endl;
}
signed main(void) {
  std::cin.tie(0);
  std::ios::sync_with_stdio(false);
  std::cout << std::fixed;
  cout << setprecision(16);
  solve();
}
