#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 10;
int n, x;
int f[100];
void process(int x) {
  if (x <= 399) {
    f[1] = 1;
    return;
  }
  if (x <= 799) {
    f[2] = 1;
    return;
  }
  if (x <= 1199) {
    f[3] = 1;
    return;
  }
  if (x < 1600) {
    f[4] = 1;
    return;
  }
  if (x < 2000) {
    f[5] = 1;
    return;
  }
  if (x < 2400) {
    f[6] = 1;
    return;
  }
  if (x < 2800) {
    f[7] = 1;
    return;
  }
  if (x < 3200) {
    f[8] = 1;
    return;
  }
  f[9]++;
}
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%d", &x);
    process(x);
  }
  int t = 0;
  for (int i = 1; i <= 8; i++) {
    t += f[i];
  }
  cout << t << " " << min(8, t + f[9]);
  return 0;
}
