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