#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<int> rate(n), color = {0, 0, 0, 0, 0, 0, 0, 0};
  for (int i = 0; i < (int)(n); i++) cin >> rate[i];
  sort((rate).begin(), (rate).end());
  int count = 0, free = 0;
  for (int i = 0; i < (int)(n); i++) {
    if (rate[i] < 400)
      color[0]++;
    else if (rate[i] < 800)
      color[1]++;
    else if (rate[i] < 1200)
      color[2]++;
    else if (rate[i] < 1600)
      color[3]++;
    else if (rate[i] < 2000)
      color[4]++;
    else if (rate[i] < 2400)
      color[5]++;
    else if (rate[i] < 2800)
      color[6]++;
    else if (rate[i] < 3200)
      color[7]++;
    else
      free++;
  }
  for (int i = 0; i < (int)(8); i++) {
    if (color[i] != 0) count++;
  }
  cout << count << " " << min(8, count + free) << endl;
}
