#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  int c1 = 0, c2 = 0, c3 = 0, c4 = 0, c5 = 0, c6 = 0, c7 = 0, c8 = 0, any = 0;
  for (int i = 0; i < n; i++) {
    int a = 0;
    cin >> a;
    if (a < 400) {
      c1 = 1;
    } else if (a < 800) {
      c2 = 1;
    } else if (a < 1200) {
      c3 = 1;
    } else if (a < 1600) {
      c4 = 1;
    } else if (a < 2000) {
      c5 = 1;
    } else if (a < 2400) {
      c6 = 1;
    } else if (a < 2800) {
      c7 = 1;
    } else if (a < 3200) {
      c8 = 1;
    } else {
      any++;
    }
  }
  int min = c1 + c2 + c3 + c4 + c5 + c6 + c7 + c8;
  int max = min + any;
  if (max > 8) {
    max = 8;
  }
  if (min == 0 && any > 0) {
    min = max;
  }
  cout << min << " " << max << endl;
  return 0;
}
