#include <bits/stdc++.h>
using namespace std;
int main() {
  bool colors[8] = {0};
  int freeColor = 0;
  int N;
  cin >> N;
  int rateMax[] = {399, 799, 1199, 1599, 1999, 2399, 2799, 3199};
  int rateMin[] = {1, 400, 800, 1200, 1600, 2000, 2400, 2800};
  for (int i = int(0); i < int(N); i++) {
    int ai;
    cin >> ai;
    for (int j = int(0); j < int(8); j++) {
      if (rateMin[j] <= ai && ai <= rateMax[j]) colors[j] = true;
    }
    if (rateMax[7] < ai) freeColor++;
  }
  int num = 0;
  for (int j = int(0); j < int(8); j++) {
    if (colors[j]) num++;
  }
  int ret1 = num;
  int ret2 = min(num + freeColor, 8);
  cout << ret1 << " " << ret2 << endl;
  return 0;
}
