#include <bits/stdc++.h>
using namespace std;
int main() {
  int N;
  cin >> N;
  vector<int> a(N), color(9, 0);
  for (int i = 0; i < N; i++) {
    cin >> a[i];
    if (1 <= a[i] && a[i] <= 399)
      color[0]++;
    else if (400 <= a[i] && a[i] <= 799)
      color[1]++;
    else if (800 <= a[i] && a[i] <= 1199)
      color[2]++;
    else if (1200 <= a[i] && a[i] <= 1599)
      color[3]++;
    else if (1600 <= a[i] && a[i] <= 1999)
      color[4]++;
    else if (2000 <= a[i] && a[i] <= 2399)
      color[5]++;
    else if (2400 <= a[i] && a[i] <= 2799)
      color[6]++;
    else if (2800 <= a[i] && a[i] <= 3199)
      color[7]++;
    else if (3200 <= a[i] && a[i] <= 4800)
      color[8]++;
  }
  int cnt = 0;
  for (int i = 0; i < 8; i++) {
    if (color[i] > 0) cnt++;
  }
  cout << cnt << " " << cnt + color[8] << endl;
}
