#include <bits/stdc++.h>
using namespace std;
const double EPS = 1e-10;
const double PI = acos(-1.0);
template <typename Iterator>
inline bool next_combination(const Iterator first, Iterator k,
                             const Iterator last) {
  if ((first == last) || (first == k) || (last == k)) return false;
  Iterator itr1 = first;
  Iterator itr2 = last;
  ++itr1;
  if (last == itr1) return false;
  itr1 = last;
  --itr1;
  itr1 = k;
  --itr2;
  while (first != itr1) {
    if (*--itr1 < *itr2) {
      Iterator j = k;
      while (!(*itr1 < *j)) ++j;
      iter_swap(itr1, j);
      ++itr1;
      ++j;
      itr2 = k;
      rotate(itr1, j, last);
      while (last != j) {
        ++j;
        ++itr2;
      }
      rotate(k, itr2, last);
      return true;
    }
  }
  rotate(first, k, last);
  return false;
}
inline double get_time_sec(void) {
  return static_cast<double>(chrono::duration_cast<chrono::nanoseconds>(
                                 chrono::steady_clock::now().time_since_epoch())
                                 .count()) /
         1000000000;
}
template <typename T>
T gcd(T a, T b) {
  if (a > b) swap(a, b);
  if (a == 0)
    return b;
  else
    return gcd(b % a, a);
}
template <typename T>
T lcm(T a, T b) {
  return (a / gcd(a, b)) * b;
}
template <typename T>
map<T, T> prime_list(T n) {
  map<T, T> ret;
  for (T i = 2; i * i <= n; i++) {
    if (n % i == 0) {
      ret[i] = 0;
      while (n % i == 0) {
        n /= i;
        ret[i]++;
      }
    }
  }
  if (n != 1) ret[n]++;
  return ret;
}
long long mypow(long long a, long long n) {
  if (n == 1) return a % 1000000007;
  if (n % 2 == 1) return (a * mypow(a, n - 1)) % 1000000007;
  long long t = mypow(a, n / 2);
  return (t * t) % 1000000007;
}
int main(void) {
  int n;
  cin >> n;
  vector<int> a(8, 0);
  int am = 0;
  for (int i = (0); i < (n); ++i) {
    int tmp;
    cin >> tmp;
    if (tmp >= 3200)
      am++;
    else if (tmp >= 2800)
      a[0] = 1;
    else if (tmp >= 2400)
      a[1] = 1;
    else if (tmp >= 2000)
      a[2] = 1;
    else if (tmp >= 1600)
      a[3] = 1;
    else if (tmp >= 1200)
      a[4] = 1;
    else if (tmp >= 800)
      a[5] = 1;
    else if (tmp >= 400)
      a[6] = 1;
    else
      a[7] = 1;
  }
  int sum = 0;
  for (int i = (0); i < (8); ++i) sum += a[i];
  cout << max(1, sum) << " " << min(8, sum + am) << endl;
}
