#include <bits/stdc++.h>
using namespace std;
int BubSort(int x[], int n) {
  int i, j, temp;
  for (i = 0; i < n - 1; i++) {
    for (j = n - 1; j > i; j--) {
      if (x[j - 1] > x[j]) {
        temp = x[j];
        x[j] = x[j - 1];
        x[j - 1] = temp;
      }
    }
  }
  return 0;
}
int main() {
  int n = 0;
  int a[4800];
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  int color[8] = {0};
  int over = 0;
  for (int j = 0; j < n; j++) {
    if (1 <= a[j] && a[j] <= 399) color[0] = 1;
    if (400 <= a[j] && a[j] <= 799) color[1] = 1;
    if (800 <= a[j] && a[j] <= 1199) color[2] = 1;
    if (1200 <= a[j] && a[j] <= 1599) color[3] = 1;
    if (1600 <= a[j] && a[j] <= 1999) color[4] = 1;
    if (2000 <= a[j] && a[j] <= 2399) color[5] = 1;
    if (2400 <= a[j] && a[j] <= 2799) color[6] = 1;
    if (2800 <= a[j] && a[j] <= 3199) color[7] = 1;
    if (3200 <= a[j]) over++;
  }
  int min = 0;
  for (int k = 0; k < 8; k++) {
    min += color[k];
  }
  if (min == 0) min = 1;
  int max = 0;
  for (int l = 0; l < 8; l++) {
    max += color[l];
  }
  max += over;
  if (max >= 8) max = 8;
  cout << min << " " << max << endl;
  ;
  return 0;
}
