#include <bits/stdc++.h>
using namespace std;
long long freq[8];
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long n;
  cin >> n;
  long long arr[n];
  long long count = 0;
  for (long long i = 0; i < n; i++) {
    cin >> arr[i];
    if (arr[i] >= 3200) {
      count++;
    }
  }
  for (long long i = 0; i < n; i++) {
    long long curr = arr[i];
    if (curr >= 1 && curr < 400) {
      freq[0]++;
    } else if (curr >= 400 && curr < 800) {
      freq[1]++;
    } else if (curr >= 800 && curr < 1200) {
      freq[2]++;
    } else if (curr >= 1200 && curr < 1600) {
      freq[3]++;
    } else if (curr >= 1600 && curr < 2000) {
      freq[4]++;
    } else if (curr >= 2000 && curr < 2400) {
      freq[5]++;
    } else if (curr >= 2400 && curr < 2800) {
      freq[6]++;
    } else if (curr >= 2800 && curr < 3200) {
      freq[7]++;
    }
  }
  long long count0 = 0;
  for (long long i = 0; i < 8; i++) {
    if (freq[i] > 0) {
      count0++;
    }
  }
  cout << count0 << " " << count + count0 << "\n";
}
