#include <bits/stdc++.h>
using ll = long long;
using ld = long double;
using namespace std;
const ll mod = 1e9 + 7;
ll a[200];
int main() {
  ll n, ans = 0, tmp = 0;
  cin >> n;
  for (ll i = ll(0); i < ll(n); i++) cin >> a[i];
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 1 && a[i] <= 399) {
      ans++;
      break;
    }
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 400 && a[i] <= 799) {
      ans++;
      break;
    }
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 800 && a[i] <= 1199) {
      ans++;
      break;
    }
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 1200 && a[i] <= 1599) {
      ans++;
      break;
    }
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 1600 && a[i] <= 1999) {
      ans++;
      break;
    }
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 2000 && a[i] <= 2399) {
      ans++;
      break;
    }
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 2400 && a[i] <= 2799) {
      ans++;
      break;
    }
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 2800 && a[i] <= 3199) {
      ans++;
      break;
    }
  for (ll i = ll(0); i < ll(n); i++)
    if (a[i] >= 3200) tmp++;
  ll k = min(ans + tmp, (ll)8);
  if (ans != 0)
    cout << ans << " ";
  else
    cout << "1"
         << " ";
  cout << k;
}
