#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  int N;
  cin >> N;
  vector<int> color(8);
  int sugoi = 0;
  for (int i = 0; i < N; i++) {
    int a;
    cin >> a;
    if (a < 400) color.at(0) = 1;
    if (a >= 400 && a < 800) color.at(1) = 1;
    if (a >= 800 && a < 1200) color.at(2) = 1;
    if (a >= 1200 && a < 1600) color.at(3) = 1;
    if (a >= 1600 && a < 2000) color.at(4) = 1;
    if (a >= 2000 && a < 2400) color.at(5) = 1;
    if (a >= 2400 && a < 2800) color.at(6) = 1;
    if (a >= 2800 && a < 3200) color.at(7) = 1;
    if (a >= 3200) sugoi++;
  }
  int sum1 = 0;
  for (int i = 0; i < 8; i++) sum1 += color.at(i);
  int sum2 = min(8, sum1 + sugoi);
  cout << sum1 << " " << sum2 << endl;
}
