#include <bits/stdc++.h>
using namespace std;
template <typename T1, typename T2>
istream &operator>>(istream &is, vector<pair<T1, T2>> &v) {
  for (pair<T1, T2> &t : v) is >> t.first >> t.second;
  return is;
}
template <typename T>
istream &operator>>(istream &is, vector<T> &v) {
  for (T &t : v) is >> t;
  return is;
}
template <typename T>
ostream &operator<<(ostream &os, const vector<T> &v) {
  for (const T &t : v) {
    os << t << " ";
  }
  os << '\n';
  return os;
}
const long long N = 200001;
double pi = acos(-1.0);
const long long md = 1e9 + 7;
const long long INF = 1e15;
long long dx1[] = {0, 0, -1, 1};
long long dy1[] = {1, -1, 0, 0};
template <class T>
T abst(T a) {
  return a < 0 ? -a : a;
}
template <class T>
T max2(T a, T b) {
  return a > b ? a : b;
}
template <class T>
T min2(T a, T b) {
  return a < b ? a : b;
}
void solve() {
  long long n;
  cin >> n;
  vector<long long> v(n);
  cin >> v;
  map<long long, long long> mp;
  long long non = 0;
  for (long long i : v) {
    if (i <= 399)
      mp[0]++;
    else if (i <= 799)
      mp[1]++;
    else if (i <= 1199)
      mp[2]++;
    else if (i <= 1599)
      mp[3]++;
    else if (i <= 1999)
      mp[4]++;
    else if (i <= 2399)
      mp[5]++;
    else if (i <= 2799)
      mp[6]++;
    else if (i <= 3199)
      mp[7]++;
    else
      non++;
  }
  long long x = max2(1LL, (long long)mp.size());
  cout << x << " " << x + non;
}
int32_t main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL);
  cout.tie(NULL);
  long long t = 1;
  for (long long i = 1; i <= t; i++) {
    solve();
  }
  return 0;
}
