#include <bits/stdc++.h>
using namespace std;
int main() {
  int N, i, a;
  int ans1 = 0;
  int ans2 = 0;
  int cnt[9];
  for (int i = 0; i < (9); i++) {
    cnt[i] = 0;
  }
  cin >> N;
  vector<int> A;
  for (int i = 0; i < (N); i++) {
    cin >> a;
    A.push_back(a);
  }
  for (int i = 0; i < (N); i++) {
    if (A[i] / 400 == 0) {
      cnt[0] = 1;
    }
    if (A[i] / 400 == 1) {
      cnt[1] = 1;
    }
    if (A[i] / 400 == 2) {
      cnt[2] = 1;
    }
    if (A[i] / 400 == 3) {
      cnt[3] = 1;
    }
    if (A[i] / 400 == 4) {
      cnt[4] = 1;
    }
    if (A[i] / 400 == 5) {
      cnt[5] = 1;
    }
    if (A[i] / 400 == 6) {
      cnt[6] = 1;
    }
    if (A[i] / 400 == 7) {
      cnt[7] = 1;
    }
    if (A[i] / 400 >= 8) {
      cnt[8] += 1;
    }
  }
  for (int i = 0; i < (8); i++) {
    ans1 += cnt[i];
  }
  if (ans1 == 0 && cnt[8] <= 7) {
    ans1 = min(1, cnt[8]);
    cout << ans1 << " " << cnt[8] << endl;
    return 0;
  }
  if (ans1 == 0 && cnt[8] > 7) {
    ans1 = 1;
    ans2 = 8;
    cout << ans1 << " " << ans2 << endl;
    return 0;
  }
  if (ans1 > 0 && ans1 + cnt[8] <= 7) {
    ans2 = ans1 + cnt[8];
    cout << ans1 << " " << ans2 << endl;
    return 0;
  }
  if (ans1 > 0 && ans1 + cnt[8] > 7) {
    ans2 = 8;
    cout << ans1 << " " << ans2 << endl;
    return 0;
  }
  return 0;
}
