#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
using ll = long long;
const int INF = 1073741823;
const int MINF = -1073741823;
const ll LINF = ll(4661686018427387903);
const ll MOD = 1000000007;
const double PI = acos(-1);
using namespace std;
void scans(string& str) {
  char c;
  scanf("%c", &c);
  if (c == '\n') scanf("%c", &c);
  while (c != '\n' && c != -1) {
    str += c;
    scanf("%c", &c);
  }
}
double acot(double x) { return PI / 2 - atan(x); }
int main() {
  int n;
  scanf("%d", &n);
  int tmp;
  unordered_map<int, bool> a;
  int freecolour = 0;
  for (int i = 0; i < (n); ++i) {
    scanf("%d", &tmp);
    if (tmp < 400) {
      a[0] = true;
    } else if (tmp < 800) {
      a[1] = true;
    } else if (tmp < 1200) {
      a[2] = true;
    } else if (tmp < 1600) {
      a[3] = true;
    } else if (tmp < 2000) {
      a[4] = true;
    } else if (tmp < 2400) {
      a[5] = true;
    } else if (tmp < 2800) {
      a[6] = true;
    } else if (tmp < 3200) {
      a[7] = true;
    } else {
      ++freecolour;
    }
  }
  int count = 0;
  for (auto aa : a) {
    count += aa.second;
  }
  printf("%d\n%d", max(1, count), min(8, count + freecolour));
  return 0;
}
