#include <bits/stdc++.h>
using namespace std;
bool z, b, c, d, e, f, g, h;
long long x, y;
signed main() {
  long long n;
  cin >> n;
  vector<long long> a(n);
  for (long long i = 0; i < n; i++) {
    cin >> a[i];
    if (a[i] < 400)
      z = true;
    else if (a[i] < 800)
      b = true;
    else if (a[i] < 1200)
      c = true;
    else if (a[i] < 1600)
      d = true;
    else if (a[i] < 2000)
      e = true;
    else if (a[i] < 2400)
      f = true;
    else if (a[i] < 2800)
      g = true;
    else if (a[i] < 3200)
      h = true;
    else
      y++;
  }
  long long mi = y;
  if (mi > 8)
    mi -= 8;
  else
    mi = 0;
  if (z) x++;
  if (c) x++;
  if (b) x++;
  if (d) x++;
  if (e) x++;
  if (f) x++;
  if (g) x++;
  if (h) x++;
  cout << mi + x << " " << y + x << endl;
}
