#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, temp, min = 0, max = 0, any = 0;
  vector<int> ratings;
  vector<bool> colors = {false, false, false, false,
                         false, false, false, false};
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> temp;
    ratings.push_back(temp);
  }
  sort(ratings.begin(), ratings.end());
  for (auto i : ratings) {
    if (i < 400)
      colors[0] = true;
    else if (i < 800)
      colors[1] = true;
    else if (i < 1200)
      colors[2] = true;
    else if (i < 1600)
      colors[3] = true;
    else if (i < 2000)
      colors[4] = true;
    else if (i < 2400)
      colors[5] = true;
    else if (i < 2800)
      colors[6] = true;
    else if (i < 3200)
      colors[7] = true;
    else
      any++;
  }
  for (auto i : colors) {
    if (i) min++;
  }
  if (min == 0 && any > 0) {
    min++;
    any--;
  }
  if (min + any > 8)
    max = 8;
  else
    max = min + any;
  cout << min << ' ' << max;
  return 0;
}
