#include <bits/stdc++.h>
using namespace std;
long long gcd(long long a, long long b) { return b ? gcd(b, a % b) : a; }
long long lcm(long long a, long long b) { return a / gcd(a, b) * b; }
signed main() {
  cout << fixed << setprecision(14);
  vector<long long> ari(8);
  long long all = 0, n;
  cin >> n;
  long long memo;
  for (long long i = 0; i < n; i++) {
    cin >> memo;
    if (memo <= 399)
      ari[0]++;
    else if (memo <= 799)
      ari[1]++;
    else if (memo <= 1199)
      ari[2]++;
    else if (memo <= 1599)
      ari[3]++;
    else if (memo <= 1999)
      ari[4]++;
    else if (memo <= 2399)
      ari[5]++;
    else if (memo <= 2799)
      ari[6]++;
    else if (memo <= 3199)
      ari[7]++;
    else
      all++;
  }
  long long ansmin = 0, ansmax = 0;
  for (long long i = 0; i < 8; i++) {
    if (ari[i] >= 1) ansmin++;
  }
  ansmax = ansmin + all;
  ansmax = min(8LL, ansmax);
  cout << ansmin << ' ' << ansmax << endl;
  return 0;
}
