#include <bits/stdc++.h>
using namespace std;
int main() {
  int32_t N;
  cin >> N;
  const int32_t RATES = 8;
  vector<int32_t> colors(RATES);
  fill(begin(colors), end(colors), 0);
  int32_t targets = 0;
  for (int32_t i = 0; i < N; i++) {
    int32_t score;
    cin >> score;
    if (score < 400)
      colors[0]++;
    else if (score < 800)
      colors[1]++;
    else if (score < 1200)
      colors[2]++;
    else if (score < 1600)
      colors[3]++;
    else if (score < 2000)
      colors[4]++;
    else if (score < 2400)
      colors[5]++;
    else if (score < 2800)
      colors[6]++;
    else if (score < 3200)
      colors[7]++;
    else
      targets++;
  }
  int32_t _min = 0;
  for (int32_t i = 0; i < RATES; i++) {
    if (colors[i] > 0) _min++;
  }
  int32_t _max;
  if (_min == 0 && targets > 0) {
    _min = 1;
    _max = _min + targets - 1;
  } else {
    _max = _min + targets;
  }
  if (_max > RATES) _max = RATES;
  cout << _min << " " << _max << endl;
  return 0;
}
