#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a[n], col[8] = {0}, red = 0;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
    if (a[i] < 400)
      col[0] = 1;
    else if (a[i] < 800)
      col[1] = 1;
    else if (a[i] < 1200)
      col[2] = 1;
    else if (a[i] < 1600)
      col[3] = 1;
    else if (a[i] < 2000)
      col[4] = 1;
    else if (a[i] < 2400)
      col[5] = 1;
    else if (a[i] < 2800)
      col[6] = 1;
    else if (a[i] < 3200)
      col[7] = 1;
    else
      red++;
  }
  int minans = 0;
  for (int i = 0; i < 8; i++) minans += col[i];
  cout << minans << " " << minans + red << endl;
}
