#include <bits/stdc++.h>
using ll = long long;
constexpr ll INF = 1000000000;
ll gcd(ll a, ll b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
ll lcm(ll a, ll b) { return a * b / gcd(a, b); }
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; i < (n); i++) cin >> a[i];
  vector<int> s(10);
  for (int i = 0; i < (n); i++) {
    if (0 < a[i] && a[i] < 400) s[0]++;
    if (400 <= a[i] && a[i] < 800) s[1]++;
    if (800 <= a[i] && a[i] < 1200) s[2]++;
    if (1200 <= a[i] && a[i] < 1600) s[3]++;
    if (1600 <= a[i] && a[i] < 2000) s[4]++;
    if (2000 <= a[i] && a[i] < 2400) s[5]++;
    if (2400 <= a[i] && a[i] < 2800) s[6]++;
    if (2800 <= a[i] && a[i] < 3200) s[7]++;
    if (3200 <= a[i]) s[8]++;
  }
  int count = 0;
  for (int i = 0; i < (8); i++) {
    if (s[i] > 0) {
      count++;
    }
  }
  cout << count << ' ' << count + s[8] << endl;
}
