#include <bits/stdc++.h>
int main(void) {
  int n, a, x[] = {0, 399, 799, 1199, 1599, 1999, 2399, 2799, 3199}, flg[10],
            cnt, cnt1, i, j;
  scanf("%d", &n);
  cnt = 0;
  for (i = 0; i < 8; i++) flg[i] = 0;
  for (i = 0; i < n; i++) {
    scanf("%d", &a);
    for (j = 0; j < 9; j++) {
      if (j == 8) {
        cnt++;
        break;
      } else if (x[j] < a && x[j + 1] >= a) {
        flg[j] = 1;
        break;
      }
    }
  }
  cnt1 = 0;
  for (i = 0; i < 8; i++) {
    if (flg[i] == 1) cnt1++;
  }
  if (cnt1 == 0)
    printf("1 ");
  else
    printf("%d ", cnt1);
  cnt1 += cnt;
  if (cnt1 < 9)
    printf("%d\n", cnt1);
  else
    printf("8\n");
  return 0;
}
