#include <bits/stdc++.h>
using namespace std;
int main() {
  int N;
  cin >> N;
  set<int> color;
  int rating, free = 0;
  for (int i = 0; i < N; ++i) {
    cin >> rating;
    if (rating < 3200) {
      color.insert(rating / 400);
    } else {
      free += 1;
    }
  }
  cout << color.size() << " " << min(8, free + int(color.size()));
  return 0;
}
