#include <bits/stdc++.h>
using namespace std;
long long mm = 1000000000;
long long MM = mm + 7;
int main() {
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; i < n; i++) {
    cin >> a.at(i);
  }
  int gra = 0;
  int br = 0;
  int gre = 0;
  int sky = 0;
  int blu = 0;
  int ye = 0;
  int ora = 0;
  int red = 0;
  int all = 0;
  for (int i = 0; i < n; i++) {
    if (a.at(i) < 400) gra++;
    if (a.at(i) >= 400 && a.at(i) < 800) br++;
    if (a.at(i) >= 800 && a.at(i) < 1200) gre++;
    if (a.at(i) >= 1200 && a.at(i) < 1600) sky++;
    if (a.at(i) >= 1600 && a.at(i) < 2000) blu++;
    if (a.at(i) >= 2000 && a.at(i) < 2400) ye++;
    if (a.at(i) >= 2400 && a.at(i) < 2800) ora++;
    if (a.at(i) >= 2800 && a.at(i) < 3200) red++;
    if (a.at(i) >= 3200) all++;
  }
  int col = 0;
  if (gra != 0) col++;
  if (br != 0) col++;
  if (gre != 0) col++;
  if (sky != 0) col++;
  if (blu != 0) col++;
  if (ye != 0) col++;
  if (ora != 0) col++;
  if (red != 0) col++;
  if (col == 0)
    cout << 1 << " ";
  else
    cout << col << " ";
  if (col + all >= 8)
    cout << 8 << endl;
  else
    cout << col + all << endl;
}
