#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<int> a;
  for (int i = 0; i < n; i++) {
    int input;
    cin >> input;
    a.push_back(input);
  }
  int rates[9];
  for (int i = 0; i < 9; i++) {
    rates[i] = 0;
  }
  for (int i = 0; i < (int)a.size(); i++) {
    int r = a[i];
    if (r < 400) rates[0]++;
    if (480 <= r && r < 800) rates[1]++;
    if (800 <= r && r < 1200) rates[2]++;
    if (1200 <= r && r < 1600) rates[3]++;
    if (1600 <= r && r < 2000) rates[4]++;
    if (2000 <= r && r < 2400) rates[5]++;
    if (2400 <= r && r < 2800) rates[6]++;
    if (2800 <= r && r < 3200) rates[7]++;
    if (3200 <= r) rates[8]++;
  }
  int cnt = 0;
  for (int i = 0; i < 8; i++) {
    if (rates[i] != 0) {
      cnt++;
    }
  }
  printf("%d %d\n", cnt, cnt + rates[8]);
  return 0;
}
