#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, i, gray = 0, brown = 0, green = 0, cyan = 0, blue = 0, yellow = 0,
            orange = 0, red = 0;
  cin >> n;
  int a[n + 2];
  int mini = 0, maxi = 0;
  for (i = 0; i < n; i++) {
    cin >> a[i];
    if (a[i] < 400) {
      gray++;
    } else if (a[i] < 800) {
      brown++;
    } else if (a[i] < 1200) {
      green++;
    } else if (a[i] < 1600) {
      cyan++;
    } else if (a[i] < 2000) {
      blue++;
    } else if (a[i] < 2400) {
      yellow++;
    } else if (a[i] < 2800) {
      orange++;
    } else if (a[i] < 3200) {
      red++;
    } else {
      maxi++;
    }
  }
  if (gray > 0) {
    mini++;
  }
  if (brown > 0) {
    mini++;
  }
  if (cyan > 0) {
    mini++;
  }
  if (green > 0) {
    mini++;
  }
  if (blue > 0) {
    mini++;
  }
  if (yellow > 0) {
    mini++;
  }
  if (orange > 0) {
    mini++;
  }
  if (red > 0) {
    mini++;
  }
  cout << mini << " " << mini + maxi << endl;
  return 0;
}
