#include <bits/stdc++.h>
const long long INF = 1LL << 60;
const int MOD = 1000000007;
using namespace std;
using vec = vector<int>;
using ll = long long;
template <class T = int>
T in() {
  T x;
  cin >> x;
  return (x);
}
template <class T>
inline bool chmin(T &a, T b) {
  if (a > b) {
    a = b;
    return 1;
  }
  return 0;
}
template <class T>
inline bool chmax(T &a, T b) {
  if (a < b) {
    a = b;
    return 1;
  }
  return 0;
}
const int dy[4] = {-1, 0, 0, 1};
const int dx[4] = {0, -1, 1, 0};
int N;
int main(int argc, char *argv[]) {
  cin >> N;
  vec A(N);
  for (int i = 0; i < (int)N; i++) cin >> A[i];
  vec R(8);
  int cnt = 0;
  for (int i = 0; i < (int)N; i++) {
    if (A[i] < 400)
      R[0]++;
    else if (400 <= A[i] && A[i] < 800)
      R[1]++;
    else if (800 <= A[i] && A[i] < 1200)
      R[2]++;
    else if (1200 <= A[i] && A[i] < 1600)
      R[3]++;
    else if (1600 <= A[i] && A[i] < 2000)
      R[4]++;
    else if (2000 <= A[i] && A[i] < 2400)
      R[5]++;
    else if (2400 <= A[i] && A[i] < 2800)
      R[6]++;
    else if (2800 <= A[i] && A[i] < 3200)
      R[7]++;
    else
      cnt++;
  }
  ll Min = INF;
  ll Max = -1;
  int color = 0;
  for (int i = 0; i < (int)8; i++) {
    if (R[i]) color++;
  }
  Min = color;
  Max = color + cnt;
  if (color == 8)
    Min = Max = 8;
  else if (Max > 8)
    Max = 8;
  cout << Min << " " << Max << endl;
  return 0;
}
