#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 7;
const int mod = 1e9 + 7;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int n;
  cin >> n;
  int a[n];
  for (int i = 0; i < n; i++) cin >> a[i];
  int rating[9] = {0, 0, 0, 0, 0, 0, 0, 0, 0};
  for (int i = 0; i < n; i++) {
    if (a[i] >= 0 && a[i] <= 399)
      rating[0] = 1;
    else if (a[i] >= 400 && a[i] <= 799)
      rating[1] = 1;
    else if (a[i] >= 800 && a[i] <= 1199)
      rating[2] = 1;
    else if (a[i] >= 1200 && a[i] <= 1599)
      rating[3] = 1;
    else if (a[i] >= 1600 && a[i] <= 1999)
      rating[4] = 1;
    else if (a[i] >= 2000 && a[i] <= 2399)
      rating[5] = 1;
    else if (a[i] >= 2400 && a[i] <= 2799)
      rating[6] = 1;
    else if (a[i] >= 2800 && a[i] <= 3199)
      rating[7] = 1;
    else if (a[i] >= 3200)
      rating[8] = 1;
  }
  long long c = 0;
  for (int i = 0; i < 8; i++) {
    c += rating[i];
  }
  if (c == 0 && rating[8] > 0) {
    c = 1;
    cout << c << " " << rating[8] << endl;
  } else if (c == 0 && rating[8] == 0)
    cout << "0"
         << " "
         << "0" << endl;
  else {
    cout << c << " ";
    cout << c + rating[8] << endl;
  }
  return 0;
}
