#include <bits/stdc++.h>
int main(void) {
  int N;
  int i;
  int min, max;
  int *a;
  int rate[9] = {0, 0, 0, 0, 0, 0, 0, 0, 0};
  char buf[1024], *ch;
  fgets(buf, sizeof(buf), stdin);
  ch = strtok(buf, " ");
  N = atoi(ch);
  a = (int *)calloc(N, sizeof(int));
  fgets(buf, sizeof(buf), stdin);
  ch = strtok(buf, " ");
  a[0] = atoi(ch);
  for (i = 1; i < N; i += 1) {
    ch = strtok(NULL, " ");
    a[i] = atoi(ch);
  }
  for (i = 0; i < N; i += 1) {
    if (a[i] >= 3200) {
      rate[8] += 1;
    } else {
      rate[a[i] / 400] = 1;
    }
  }
  min = 0;
  max = 0;
  for (i = 0; i < 8; i += 1) {
    min += rate[i];
    max += rate[i];
  }
  max += rate[8];
  printf("%d %d\n", min, max);
  free(a);
  return 0;
}
