#include <bits/stdc++.h>
int main() {
  int n, a, flg = 0, ofs = 0, kind = 0;
  scanf("%d", &n);
  for (int i = 0; i < n; ++i) {
    scanf("%d", &a);
    if (1 <= a && a <= 399) {
      flg |= 0x1;
    } else if (400 <= a && a <= 799) {
      flg |= 0x2;
    } else if (800 <= a && a <= 1199) {
      flg |= 0x4;
    } else if (1200 <= a && a <= 1599) {
      flg |= 0x8;
    } else if (1600 <= a && a <= 1999) {
      flg |= 0x10;
    } else if (2000 <= a && a <= 2399) {
      flg |= 0x20;
    } else if (2400 <= a && a <= 2799) {
      flg |= 0x40;
    } else if (2800 <= a && a <= 3199) {
      flg |= 0x80;
    } else {
      ofs = n - i;
      break;
    }
  }
  while (flg) {
    if (flg & 0x1) {
      ++kind;
    }
    flg >>= 0x1;
  }
  printf("%d %d", kind, kind + ofs);
  return 0;
}
