#include <bits/stdc++.h>
using namespace std;
int n, x, biras;
set<int> s;
void f() {
  if (1 <= x && x <= 399) {
    s.insert(1);
  } else if (400 <= x && x <= 799) {
    s.insert(2);
  } else if (800 <= x && x <= 1199) {
    s.insert(3);
  } else if (1200 <= x && x <= 1599) {
    s.insert(4);
  } else if (1600 <= x && x <= 1999) {
    s.insert(5);
  } else if (2000 <= x && x <= 2399) {
    s.insert(6);
  } else if (2400 <= x && x <= 2799) {
    s.insert(7);
  } else if (2800 <= x && x <= 3199) {
    s.insert(8);
  } else {
    biras++;
  }
}
int main() {
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> x;
    f();
  }
  int br = s.size();
  if (br > 0) {
    cout << br << " ";
    if (biras + br > 8)
      cout << 8;
    else
      cout << biras + br;
  } else {
    cout << 0 << " ";
    if (biras > 8)
      cout << 8;
    else
      cout << biras;
  }
  cout << endl;
  return 0;
}
