#include <bits/stdc++.h>
using ll = long long;
using namespace std;
void solve() {
  int n, count = 0, count2 = 0;
  bool flag[8];
  vector<int> a;
  for (int i = 0; i < 8; i++) {
    flag[i] = true;
  }
  cin >> n;
  for (int i = 0; i < n; i++) {
    int x;
    cin >> x;
    a.push_back(x);
    if (x < 400 && flag[0]) {
      count++;
      flag[0] = false;
    } else if (x >= 400 && x < 800 && flag[1]) {
      count++;
      flag[1] = false;
    } else if (x >= 800 && x < 1200 && flag[2]) {
      count++;
      flag[2] = false;
    } else if (x >= 1200 && x < 1600 && flag[3]) {
      count++;
      flag[3] = false;
    } else if (x >= 1600 && x < 2000 && flag[4]) {
      count++;
      flag[4] = false;
    } else if (x >= 2000 && x < 2400 && flag[5]) {
      count++;
      flag[5] = false;
    } else if (x >= 2400 && x < 2800 && flag[6]) {
      count++;
      flag[6] = false;
    } else if (x >= 2800 && x < 3200 && flag[7]) {
      count++;
      flag[7] = false;
    } else if (x >= 3200) {
      count2++;
    }
  }
  cout << count << " " << count + count2 << endl;
}
int main() {
  solve();
  return 0;
}
