#include <bits/stdc++.h>
using namespace std;
template <class T>
inline bool chmax(T& a, T b) {
  if (a < b) {
    a = b;
    return 1;
  }
  return 0;
}
template <class T>
inline bool chmin(T& a, T b) {
  if (a > b) {
    a = b;
    return 1;
  }
  return 0;
}
template <typename T>
using min_priority_queue = priority_queue<T, vector<T>, greater<T>>;
const long long INF = 1LL << 60;
const long long MOD = 1e9 + 7;
long long color(long long a) {
  if ((1 <= a) && (a <= 399))
    return 0;
  else if ((400 <= a) && (a <= 799))
    return 1;
  else if ((800 <= a) && (a <= 1199))
    return 2;
  else if ((1200 <= a) && (a <= 1599))
    return 3;
  else if ((1600 <= a) && (a <= 1999))
    return 4;
  else if ((2000 <= a) && (a <= 2399))
    return 5;
  else if ((2400 <= a) && (a <= 2799))
    return 6;
  else if ((2800 <= a) && (a <= 3199))
    return 7;
  else if (3200 <= a)
    return 8;
}
int main() {
  long long N;
  cin >> N;
  vector<long long> vec(9);
  for (long long i = 0; i < N; i++) {
    long long a = 0;
    cin >> a;
    long long c = color(a);
    vec.at(c) += 1;
  }
  long long cnt = 0;
  for (long long i = 0; i < 8; i++) {
    if (vec.at(i) != 0) cnt++;
  }
  long long m;
  if (cnt >= vec.at(8))
    m = cnt;
  else if (vec.at(8) <= 8)
    m = vec.at(8);
  else
    m = 8;
  long long M;
  if (cnt + vec.at(8) <= 8)
    M = cnt + vec.at(8);
  else
    M = 8;
  cout << m << " " << M << endl;
}
