#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using dll = deque<ll>;
using pll = pair<ll, ll>;
using qll = queue<ll>;
using usll = unordered_set<ll>;
using umll = unordered_map<ll, ll>;
using sll = stack<int>;
using vll = vector<ll>;
using vvll = vector<vll>;
constexpr ll kMod = 1e9 + 7;
ll gcd(ll a, ll b) {
  if (a < b) {
    return gcd(b, a);
  }
  ll c = a % b;
  while (c != 0) {
    a = b;
    b = c;
    c = a % b;
  }
  return b;
}
ll lcm(ll a, ll b) { return a / gcd(a, b) * b; }
void init() {
  cin.tie(nullptr);
  ios_base::sync_with_stdio(false);
  cout << fixed << setprecision(15);
}
int main() {
  init();
  ll N;
  cin >> N;
  vll M(9, 0);
  for (ll(i) = (0); (i) < (N); (i)++) {
    ll a;
    cin >> a;
    if (a < 400) {
      M[0]++;
    } else if (a < 800) {
      M[1]++;
    } else if (a < 1200) {
      M[2]++;
    } else if (a < 1600) {
      M[3]++;
    } else if (a < 2000) {
      M[4]++;
    } else if (a < 2400) {
      M[5]++;
    } else if (a < 2800) {
      M[6]++;
    } else if (a < 3200) {
      M[7]++;
    } else {
      M[8]++;
    }
  }
  bool all_none = true;
  ll min = 0, max = 0;
  for (ll(i) = (0); (i) < (8); (i)++) {
    if (M[i] > 0) {
      all_none = false;
      min++;
      max++;
    }
  }
  if (all_none) {
    ll m8 = M[8];
    if (m8 <= 8) {
      cout << "1 " << M[8] << endl;
    } else {
      cout << "1 8" << endl;
    }
  }
  max += M[8];
  cout << min << " " << max << endl;
  return 0;
}
