#include <bits/stdc++.h>
using namespace std;

#define rep(i, n) for (int i = 0; i < (int)(n); i++)
template<class T> inline bool chmax(T& a, T b) {
  if (a < b) {
    a = b;
    return 1;
  }
  return 0;
}
template<class T> inline bool chmin(T& a, T b) {
  if (a > b) {
    a = b;
    return 1;
  }
  return 0;
}
int64_t abs(int64_t n) {
  if (n < 0) {
    n = -n;
  }
  return n;
}
int ctoi(char c) {
  if (c >= '0' && c <= '9') {
    return c - '0';
  }
  return 0;
}

int main() {
  int n;
  cin >> n;
  int n1 = 0, n2 = 0, n3 = 0, n4 = 0, n5 = 0, n6 = 0, n7 = 0, n8 = 0, n9 = 0;
  rep(i, n) {
    int a;
    cin >> a;
    if (a < 400) {
      n1 = 1;
    } else if (a < 800) {
      n2 = 1;
    } else if (a < 1200) {
      n3 = 1;
    } else if (a < 1600) {
      n4 = 1;
    } else if (a < 2000) {
      n5 = 1;
    } else if (a < 2400) {
      n6 = 1;
    } else if (a < 2800) {
      n7 = 1;
    } else if (a < 3200) {
      n8 = 1;
    } else {
      n9++;
    }
  }
  if (n1+n2+n3+n4+n5+n6+n7+n8+n9 > 8) {
    cout << 8 << ' ' << n1+n2+n3+n4+n5+n6+n7+n8 << endl;
  } else {
    cout << n1+n2+n3+n4+n5+n6+n7+n8+n9 << ' ' << n1+n2+n3+n4+n5+n6+n7+n8 << endl;
  }
}