#include <bits/stdc++.h>
using namespace std;
int main(int argc, const char* argv[]) {
  int N;
  int minn, maxn;
  int result = 0;
  cin >> N;
  int excolor = 0;
  vector<bool> color(8, 0);
  for (int i = 0; i < N; i++) {
    int tmp;
    cin >> tmp;
    if (tmp < 400) {
      color[0] = 1;
    } else if (tmp < 800) {
      color[1] = 1;
    } else if (tmp < 1200) {
      color[2] = 1;
    } else if (tmp < 1600) {
      color[3] = 1;
    } else if (tmp < 2000) {
      color[4] = 1;
    } else if (tmp < 2400) {
      color[5] = 1;
    } else if (tmp < 2800) {
      color[6] = 1;
    } else if (tmp < 3200) {
      color[7] = 1;
    } else {
      excolor++;
    }
  }
  for (int j = 0; j < 8; j++) {
    if (color[j] == 1) result++;
  }
  if (excolor + result >= 8) {
    maxn = 8;
  } else {
    maxn = excolor + result;
  }
  minn = result;
  cout << minn << " " << maxn;
  return 0;
}
