#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int N, min, max;
  cin >> N;
  vector<int> color(9);
  for (int i = 0; i < 9; i++) {
    color[i] = 0;
  }
  min = 0;
  max = 0;
  for (int i = 0; i < N; i++) {
    int tmp;
    cin >> tmp;
    if (tmp >= 1 && tmp < 400) {
      color[0]++;
    } else if (tmp >= 400 && tmp < 800) {
      color[1]++;
    } else if (tmp >= 800 && tmp < 1200) {
      color[2]++;
    } else if (tmp >= 1200 && tmp < 1600) {
      color[3]++;
    } else if (tmp >= 1600 && tmp < 2000) {
      color[4]++;
    } else if (tmp >= 2000 && tmp < 2400) {
      color[5]++;
    } else if (tmp >= 2400 && tmp < 2800) {
      color[6]++;
    } else if (tmp >= 2800 && tmp < 3200) {
      color[7]++;
    } else if (tmp >= 3200 && tmp <= 4800) {
      color[8]++;
    }
  }
  for (int i = 0; i < 9; i++) {
    max = color[i] != 0 && i != 8 ? max + 1 : max;
    min = color[i] != 0 && i != 8 ? min + 1 : min;
  }
  max = color[8] + max;
  cout << min << " " << max << endl;
  return 0;
}
