#include <bits/stdc++.h>
using namespace std;
long long int n, cnt = 0, ans = 0, a[100000], b = 0, c = 0, tmp = 0;
string s, w;
int main(void) {
  bool flag[10] = {false};
  cin >> n;
  for (long long int(i) = 0; (i) < (int)(n); (i)++) {
    cin >> a[i];
  }
  for (long long int(i) = 0; (i) < (int)(n); (i)++) {
    if (flag[0] == false && a[i] >= 1 && a[i] <= 399) {
      flag[0] = true;
      b++;
      c++;
    } else if (flag[1] == false && a[i] >= 400 && a[i] <= 799) {
      flag[1] = true;
      b++;
      c++;
    } else if (flag[2] == false && a[i] >= 800 && a[i] <= 1199) {
      flag[2] = true;
      b++;
      c++;
    } else if (flag[3] == false && a[i] >= 1200 && a[i] <= 1599) {
      flag[3] = true;
      b++;
      c++;
    } else if (flag[4] == false && a[i] >= 1600 && a[i] <= 1999) {
      flag[4] = true;
      b++;
      c++;
    } else if (flag[5] == false && a[i] >= 2000 && a[i] <= 2399) {
      flag[5] = true;
      b++;
      c++;
    } else if (flag[6] == false && a[i] >= 2400 && a[i] <= 2799) {
      flag[6] = true;
      b++;
      c++;
    } else if (flag[7] == false && a[i] >= 2800 && a[i] <= 3199) {
      flag[7] = true;
      b++;
      c++;
    } else if (a[i] >= 3200) {
      c++;
    }
  }
  for (long long int(i) = 0; (i) < (int)(n); (i)++) {
    if (a[i] == 3200) {
      cnt++;
    }
  }
  if (cnt == n) {
    b++;
  }
  cout << b << " " << c << endl;
  return 0;
}
