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