#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, c1 = 0, c2 = 0, c3 = 0, c4 = 0, c5 = 0, c6 = 0, c7 = 0, c8 = 0, c9 = 0,
         mi = 0, ma = 0;
  cin >> n;
  int a[n];
  for (int i = 0; i < n; i++) {
    cin >> a[i];
    if (a[i] < 400)
      c1++;
    else if (a[i] < 700)
      c2++;
    else if (a[i] < 1200)
      c3++;
    else if (a[i] < 1600)
      c4++;
    else if (a[i] < 2000)
      c5++;
    else if (a[i] < 2400)
      c6++;
    else if (a[i] < 2800)
      c7++;
    else if (a[i] < 3200)
      c8++;
    else
      c9++;
  }
  if (c1 != 0) c1 = 1;
  if (c2 != 0) c2 = 1;
  if (c3 != 0) c3 = 1;
  if (c4 != 0) c4 = 1;
  if (c5 != 0) c5 = 1;
  if (c6 != 0) c6 = 1;
  if (c7 != 0) c7 = 1;
  if (c8 != 0) c8 = 1;
  mi = c1 + c2 + c3 + c4 + c5 + c6 + c7 + c8;
  ma = mi + c9;
  cout << mi << " " << ma << endl;
  return 0;
}
