#include <bits/stdc++.h>
int main(void) {
  int N;
  scanf("%d", &N);
  int a, i;
  int grade[9] = {0};
  for (i = 0; i < N; i++) {
    scanf("%d", &a);
    if (grade[0] == 0 && a < 400) {
      grade[0] = 1;
    } else if (grade[1] == 0 && a > 399 && a < 800) {
      grade[1] = 1;
    } else if (grade[2] == 0 && a > 799 && a < 1200) {
      grade[2] = 1;
    } else if (grade[3] == 0 && a > 1199 && a < 1600) {
      grade[3] = 1;
    } else if (grade[4] == 0 && a > 1599 && a < 2000) {
      grade[4] = 1;
    } else if (grade[5] == 0 && a > 1999 && a < 2400) {
      grade[5] = 1;
    } else if (grade[6] == 0 && a > 2399 && a < 2800) {
      grade[6] = 1;
    } else if (grade[7] == 0 && a > 2799 && a < 3200) {
      grade[7] = 1;
    } else if (a > 3199) {
      grade[8] += 1;
    }
  }
  int max = 0, min = 0;
  for (i = 0; i < 8; i++) {
    min += grade[i];
  }
  max = min + grade[8];
  printf("%d %d\n", min, max);
  return 0;
}
