#include <bits/stdc++.h>
using namespace std;
using ll = long long;
const int INF = 1001001001;
const int MOD = 1000000007;
template <typename T>
void print(const T &v);
int main() {
  int N;
  cin >> N;
  vector<int> vec(8);
  int op = 0;
  for (int i = 0; i < N; i++) {
    int a;
    cin >> a;
    if (a < 400)
      vec.at(0) = 1;
    else if (a < 800)
      vec.at(1) = 1;
    else if (a < 1200)
      vec.at(2) = 1;
    else if (a < 1600)
      vec.at(3) = 1;
    else if (a < 2000)
      vec.at(4) = 1;
    else if (a < 2400)
      vec.at(5) = 1;
    else if (a < 2800)
      vec.at(6) = 1;
    else if (a < 3200)
      vec.at(7) = 1;
    else
      op++;
  }
  int cnt = 0;
  for (int i = 0; i < 8; i++) {
    if (vec.at(i) == 1) cnt++;
  }
  cout << cnt << " " << cnt + op << endl;
  return 0;
}
template <typename T>
void print(T const &v) {
  for (int i = 0; i < v.size(); i++) {
    if (i) cout << " ";
    cout << v[i];
  }
  cout << endl;
}
