#include <bits/stdc++.h>
using namespace std;
void solve(long long N, std::vector<long long> A) {
  set<long long> colors;
  int ns = 0;
  for (auto a : A) {
    if (a / 400 < 8)
      colors.insert(a / 400);
    else
      ns++;
  }
  int nf = colors.size();
  cout << max(nf, ns) << " " << min(8, nf + ns) << endl;
}
int main() {
  long long N;
  scanf("%lld", &N);
  std::vector<long long> a(N);
  for (int i = 0; i < N; i++) {
    scanf("%lld", &a[i]);
  }
  solve(N, std::move(a));
  return 0;
}
