#include <bits/stdc++.h>
using namespace std;
int main() {
  int N;
  int rating, cont = 0, resp = 0;
  cin >> N;
  int Color[8] = {0, 0, 0, 0, 0, 0, 0, 0};
  for (int i = 0; i < N; i++) {
    cin >> rating;
    if (rating < 400) {
      Color[0] = 1;
    } else if (rating < 800) {
      Color[1] = 1;
    } else if (rating < 1200) {
      Color[2] = 1;
    } else if (rating < 1600) {
      Color[3] = 1;
    } else if (rating < 2000) {
      Color[4] = 1;
    } else if (rating < 2400) {
      Color[5] = 1;
    } else if (rating < 2800) {
      Color[6] = 1;
    } else if (rating < 3200) {
      Color[7] = 1;
    } else {
      cont++;
    }
  }
  for (int i = 0; i < 8; i++) {
    if (Color[i]) {
      resp++;
    }
  }
  cout << resp << " " << resp + cont << endl;
  return 0;
}
