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