#include <bits/stdc++.h>
using namespace std;
template <typename T>
using reversed_priority_queue =
    std::priority_queue<T, std::vector<T>, std::greater<T> >;
signed main() {
  map<long long int, long long int> mp;
  mp.emplace(399, 1);
  mp.emplace(799, 2);
  mp.emplace(1199, 3);
  mp.emplace(1599, 4);
  mp.emplace(1999, 5);
  mp.emplace(2399, 6);
  mp.emplace(2799, 7);
  mp.emplace(3199, 8);
  set<long long int> colours;
  long long int N, t = 0;
  cin >> N;
  for (long long int i = (0); i < (N); i++) {
    long long int a;
    cin >> a;
    if (a >= 3200) {
      t++;
    } else {
      auto it = mp.lower_bound(a);
      colours.insert(it->second);
    }
  }
  cout << colours.size() << " " << (colours.size() + t) << endl;
  return 0;
}
