#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, gray, brown, green, lightblue, yellow, orange, red, almighty;
  cin >> n;
  vector<int> a(n);
  gray = brown = green = lightblue = yellow = orange = red = almighty = 0;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
    if (a[i] < 400)
      gray = 1;
    else if (a[i] < 800)
      brown = 1;
    else if (a[i] < 1200)
      green = 1;
    else if (a[i] < 1600)
      lightblue = 1;
    else if (a[i] < 2400)
      yellow = 1;
    else if (a[i] < 2800)
      orange = 1;
    else if (a[i] < 3200)
      red = 1;
    else
      almighty++;
  }
  red = gray + brown + green + lightblue + yellow + orange + red;
  if (red >= almighty)
    cout << red << " " << red + almighty << endl;
  else
    cout << almighty << " " << red + almighty << endl;
}
