#include <bits/stdc++.h>
int main(void) {
  int n, i, a[100], flg[8], b = 0, c = 0;
  scanf("%d", &n);
  for (i = 0; i < n; i++) {
    scanf("%d", &a[i]);
  }
  for (i = 0; i < 8; i++) flg[i] = 0;
  for (i = 0; i < n; i++) {
    if (a[i] < 400)
      flg[0] = 1;
    else if (a[i] < 800)
      flg[1] = 1;
    else if (a[i] < 1200)
      flg[2] = 1;
    else if (a[i] < 1600)
      flg[3] = 1;
    else if (a[i] < 2000)
      flg[4] = 1;
    else if (a[i] < 2400)
      flg[5] = 1;
    else if (a[i] < 2800)
      flg[6] = 1;
    else if (a[i] < 3200)
      flg[7] = 1;
    else if (a[i] >= 3200)
      b++;
  }
  for (i = 0; i < 8; i++) {
    if (flg[i] == 1) {
      b++;
      c++;
    }
  }
  printf("%d %d\n", c, b);
  return 0;
}
