#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int n;
  cin >> n;
  vector<int> rate(n);
  int color[8] = {};
  int cnt = 0;
  for (int i = 0; i < n; i++) {
    cin >> rate.at(i);
    if (rate.at(i) >= 3200)
      cnt++;
    else if (rate.at(i) < 400)
      color[0]++;
    else if (rate.at(i) >= 400 && rate.at(i) < 800)
      color[1]++;
    else if (rate.at(i) >= 800 && rate.at(i) < 1200)
      color[2]++;
    else if (rate.at(i) >= 1200 && rate.at(i) < 1600)
      color[3]++;
    else if (rate.at(i) >= 1600 && rate.at(i) < 2000)
      color[4]++;
    else if (rate.at(i) >= 2000 && rate.at(i) < 2400)
      color[5]++;
    else if (rate.at(i) >= 2400 && rate.at(i) < 2800)
      color[6]++;
    else if (rate.at(i) >= 2800 && rate.at(i) < 3200)
      color[7]++;
  }
  int minans = 0;
  for (int i = 0; i < 8; i++) {
    if (color[i] != 0) minans++;
  }
  cout << minans << " " << minans + cnt << endl;
  return 0;
}
