#include <bits/stdc++.h>
int main(void) {
  int color[9], i, max = 0, min = 0, n, score;
  for (i = 0; i < 9; i++) color[i] = 0;
  scanf("%d", &n);
  while (n > 0) {
    scanf("%d", &score);
    if (score < 400)
      color[0]++;
    else if (score < 800)
      color[1]++;
    else if (score < 1200)
      color[2]++;
    else if (score < 1600)
      color[3]++;
    else if (score < 2000)
      color[4]++;
    else if (score < 2400)
      color[5]++;
    else if (score < 2800)
      color[6]++;
    else if (score < 3200)
      color[7]++;
    else
      color[8]++;
    n--;
  }
  for (i = 0; i < 8; i++)
    if (color[i] != 0) max = ++min;
  printf("%d %d", min, max + color[8]);
  return 0;
}
