#include <bits/stdc++.h>
using namespace std;
unsigned long long int poW(long long int x, unsigned long long int y) {
  long long int temp;
  if (y == 0) return 1;
  temp = poW(x, y / 2);
  if (y % 2 == 0)
    return temp * temp;
  else
    return x * temp * temp;
}
int bSearch(int low, int high, int a[], int sh) {
  while (low < high) {
    int mid = low + (high - low + 1) / 2;
    if (a[mid] > sh) high = mid - 1;
    if (a[mid] <= sh) low = mid;
  }
  return low;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  ;
  int n;
  cin >> n;
  map<int, int> m;
  int counter3 = 0;
  for (int i = 0; i < (n); i++) {
    int x;
    cin >> x;
    if (x < 400)
      m[0] = 1;
    else if (x >= 400 && x < 800)
      m[1] = 1;
    else if (x >= 800 && x < 1200)
      m[2] = 1;
    else if (x >= 1200 && x < 1600)
      m[3] = 1;
    else if (x >= 1600 && x < 2000)
      m[4] = 1;
    else if (x >= 2000 && x < 2400)
      m[5] = 1;
    else if (x >= 2400 && x < 2800)
      m[6] = 1;
    else if (x >= 2800 && x < 3200)
      m[7] = 1;
    else if (x >= 3200)
      counter3++;
  }
  if (counter3 == 0)
    cout << m.size() << " " << m.size() << "\n";
  else if (counter3 == 1) {
    if (m.size() == 8) cout << m.size() << " " << m.size() << "\n";
    if (m.size() <= 7) cout << m.size() << " " << m.size() + 1 << "\n";
  } else {
    if (m.size() == 8) cout << m.size() << " " << m.size() << "\n";
    if (m.size() == 7)
      cout << m.size() << " " << m.size() + 1 << "\n";
    else
      cout << m.size() << " " << m.size() + 2 << "\n";
  }
}
