#include <bits/stdc++.h>
using namespace std;
int main() {
  int N, k, count1 = 0, count2 = 0;
  cin >> N;
  vector<int> a(N);
  vector<int> count(8, 0);
  for (int i = 0; i < N; i++) cin >> a.at(i);
  for (int i = 0; i < N; i++) {
    k = a.at(i);
    if (1 <= k && k < 400)
      count.at(0)++;
    else if (400 <= k && k < 800)
      count.at(1)++;
    else if (800 <= k && k < 1200)
      count.at(2)++;
    else if (1200 <= k && k < 1600)
      count.at(3)++;
    else if (1600 <= k && k < 2000)
      count.at(4)++;
    else if (2000 <= k && k < 2400)
      count.at(5)++;
    else if (2400 <= k && k < 2800)
      count.at(6)++;
    else if (2800 <= k && k < 3200)
      count.at(7)++;
    else if (3200 <= k)
      count2++;
  }
  for (int i = 0; i < 8; i++) {
    if (count.at(i) > 0) count1++;
  }
  cout << count1 << " " << count1 + count2 << endl;
  return 0;
}
