#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; i < n; i++) cin >> a[i];
  sort(a.begin(), a.end());
  int l = 0, b = 0, c = 0, d = 0, e = 0, f = 0, g = 0, h = 0, j = 0;
  for (int i = 0; i < n; i++) {
    if (a[i] < 400) {
      l++;
    }
    if (a[i] < 800 && a[i] >= 400) {
      b++;
    }
    if (a[i] < 1200 && a[i] >= 800) {
      c++;
    }
    if (a[i] < 1600 && a[i] >= 1200) {
      d++;
    }
    if (a[i] < 2000 && a[i] >= 1600) {
      e++;
    }
    if (a[i] < 2400 && a[i] >= 2000) {
      f++;
    }
    if (a[i] < 2800 && a[i] >= 2400) {
      g++;
    }
    if (a[i] < 3200 && a[i] >= 2800) {
      h++;
    }
    if (a[i] >= 3200) {
      j++;
    }
  }
  int k = 0;
  if (l != 0) {
    k++;
  }
  if (b != 0) {
    k++;
  }
  if (c != 0) {
    k++;
  }
  if (d != 0) {
    k++;
  }
  if (e != 0) {
    k++;
  }
  if (f != 0) {
    k++;
  }
  if (g != 0) {
    k++;
  }
  if (h != 0) {
    k++;
  }
  cout << k << ' ' << k + j;
  return 0;
}
