#include <bits/stdc++.h>
using namespace std;
int main() {
  map<int, int> mp;
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    int a;
    cin >> a;
    mp[min(8, a / 400)]++;
  }
  int M = 0, m = 0;
  for (auto x : mp) {
    if (x.first < 8) {
      m++, M++;
    } else {
      M += x.second;
    }
  }
  cout << m << " " << M << endl;
}
