#include <bits/stdc++.h>
using namespace std;
constexpr int MOD = 1000000007;
constexpr int dx[] = {1, 0, -1, 0, 1, 1, -1, -1};
constexpr int dy[] = {0, -1, 0, 1, 1, -1, -1, 1};
template <typename T>
ostream &operator<<(ostream &os, const vector<T> &vec) {
  os << "[";
  for (const auto &v : vec) {
    os << v << ",";
  }
  os << "]";
  return os;
}
template <typename T, typename U>
ostream &operator<<(ostream &os, const pair<T, U> &p) {
  os << "(" << p.first << ", " << p.second << ")";
  return os;
}
int f(int x) {
  if (x < 400) return 0;
  if (x < 800) return 1;
  if (x < 1200) return 2;
  if (x < 1600) return 3;
  if (x < 2000) return 4;
  if (x < 2400) return 5;
  if (x < 3200) return 6;
  return -1;
}
void solve() {
  int N;
  cin >> N;
  vector<int> A(N);
  int cnt = 0;
  set<int> S;
  for (int i = 0; i < N; i++) {
    cin >> A[i];
    if (A[i] >= 3200)
      cnt++;
    else
      S.insert(f(A[i]));
  }
  if (cnt == N) {
    cout << 1 << " " << N << endl;
    return;
  } else if (cnt > 0) {
    cout << S.size() << " " << S.size() + cnt << endl;
    return;
  } else {
    cout << S.size() << " " << S.size() << endl;
  }
}
int main() {
  std::cin.tie(0);
  std::ios::sync_with_stdio(false);
  cout.setf(ios::fixed);
  cout.precision(16);
  solve();
  return 0;
}
