#include <bits/stdc++.h>
using namespace std;
const int mod = 1000000007;
const double EPS = 1e-10;
int a[9];
int n;
int main() {
  cin >> n;
  for (int i = 0; i < n; i++) {
    int t;
    cin >> t;
    if (1 <= t && t <= 399) a[0]++;
    if (400 <= t && t <= 799) a[1]++;
    if (800 <= t && t <= 1199) a[2]++;
    if (1200 <= t && t <= 1599) a[3]++;
    if (1600 <= t && t <= 1999) a[4]++;
    if (2000 <= t && t <= 2399) a[5]++;
    if (2400 <= t && t <= 2799) a[6]++;
    if (2800 <= t && t <= 3199) a[7]++;
    if (3200 <= t) a[8]++;
  }
  int sum = 0;
  for (int i = 0; i < 8; i++) {
    if (a[i]) sum++;
  }
  cout << sum << " " << sum + a[8] << endl;
  return 0;
}
