#include <bits/stdc++.h>
int cmpfunc(const void *a, const void *b) { return (*(int *)a - *(int *)b); }
int main(void) {
  int n, i;
  scanf("%d", &n);
  int a[n];
  for (i = 0; i < n; i++) scanf("%d", &a[i]);
  int c[8];
  for (i = 0; i < 8; i++) c[i] = 0;
  int freec = 0;
  for (i = 0; i < n; i++) {
    if (a[i] <= 399)
      c[0]++;
    else if (a[i] <= 799)
      c[1]++;
    else if (a[i] <= 1199)
      c[2]++;
    else if (a[i] <= 1599)
      c[3]++;
    else if (a[i] <= 1999)
      c[4]++;
    else if (a[i] <= 2399)
      c[5]++;
    else if (a[i] <= 2799)
      c[6]++;
    else if (a[i] <= 3199)
      c[7]++;
    else
      freec++;
  }
  int min = 0, max = 0;
  for (i = 0; i < 8; i++) {
    if (c[i] != 0) {
      min++;
      max++;
    }
  }
  if (freec + max >= 8)
    max = 8;
  else
    max += freec;
  min = (min > freec) ? min : freec;
  printf("%d %d\n", min, max);
  return 0;
}
