#include <bits/stdc++.h>
using namespace std;
int N;
int cnt_color[8];
void color(int x) {
  if (x <= 399)
    ++cnt_color[0];
  else if (x <= 799)
    ++cnt_color[1];
  else if (x <= 1199)
    ++cnt_color[2];
  else if (x <= 1599)
    ++cnt_color[3];
  else if (x <= 1999)
    ++cnt_color[4];
  else if (x <= 2399)
    ++cnt_color[5];
  else if (x <= 2799)
    ++cnt_color[6];
  else if (x <= 3199)
    ++cnt_color[7];
}
int main() {
  ios_base::sync_with_stdio(false);
  cin >> N;
  int legends = 0;
  for (int i = 0; i < N; ++i) {
    int x;
    cin >> x;
    if (x < 3200)
      color(x);
    else
      ++legends;
  }
  int res_min = 0, res_max = 0;
  if (legends == 0) {
    for (int i = 0; i < 8; ++i) res_min += (cnt_color[i] > 0);
    res_max = res_min;
  } else {
    for (int i = 0; i < 8; ++i) res_min += (cnt_color[i] > 0);
    for (int i = 0; i < 8; ++i) {
      res_max += (cnt_color[i] > 0);
    }
    res_max += legends;
  }
  cout << res_min << " " << res_max << "\n";
  return 0;
}
