#include <bits/stdc++.h>
using namespace std;
const int a[] = {1, 400, 800, 1200, 1600, 2000, 2400, 2800};
const int b[] = {399, 799, 1199, 1599, 1999, 2399, 2799, 3199};
int n;
const int N = 10;
int f[N];
void nhap() { scanf("%d", &n); }
int vt(int x) {
  for (int i = 0; i < 8; i++) {
    if (x >= a[i] && x <= b[i]) {
      return i;
    }
  }
  return 8;
}
void init() {
  for (int i = 0; i <= N; i++) {
    f[i] = 0;
  }
  for (int i = 1; i <= n; i++) {
    int x;
    scanf("%d", &x);
    int vitri = vt(x);
    f[vitri]++;
  }
}
void solve() {
  int res = 0;
  for (int i = 0; i < 8; i++) {
    if (f[i] > 0) {
      res++;
    }
  }
  cout << res << " ";
  int kq = min(9, res + min(f[8], (8 - res)));
  cout << kq << endl;
}
int main() {
  nhap();
  init();
  solve();
  return 0;
}
