#include <bits/stdc++.h>
int f[8];
int main(int argc, char const *argv[]) {
  int n, a, i, j, m = 0, g = 0, M;
  scanf("%d", &n);
  for (i = 0; i < n; i++) {
    scanf("%d", &a);
    for (j = 1; j < 9; j++) {
      if (a < 400 * j) {
        f[j - 1] = 1;
        break;
      }
    }
    if (j == 9) g++;
  }
  for (i = 0; i < 8; i++) {
    m += f[i];
  }
  M = m;
  if (m == 0) m++;
  M = (((M + g) < (8)) ? (M + g) : (8));
  printf("%d %d\n", m, M);
  return 0;
}
