#include <bits/stdc++.h>
using namespace std;
long long MOD = 1000000007;
long long F[100001] = {0};
int main() {
  long long N;
  cin >> N;
  long long a[100];
  bool b[9] = {};
  long long all = 0;
  for (long long i = 0; i < N; i++) {
    long long A;
    cin >> A;
    if (A < 400)
      b[0] = true;
    else if (A < 800)
      b[1] = true;
    else if (A < 1200)
      b[2] = true;
    else if (A < 1600)
      b[3] = true;
    else if (A < 2000)
      b[4] = true;
    else if (A < 2400)
      b[5] = true;
    else if (A < 2800)
      b[6] = true;
    else if (A < 3200)
      b[7] = true;
    else if (A >= 3200)
      all++;
  }
  long long cnt = 0;
  for (long long i = 0; i <= 8; i++) {
    if (b[i]) cnt++;
  }
  long long max = cnt + all;
  if (all >= 8) {
    max == 8;
  }
  cout << cnt << " " << max << endl;
  return 0;
}
