#include <bits/stdc++.h>
using namespace std;
int getcolor(int n) {
  if (n < 400)
    return 1;
  else if (n < 800)
    return 2;
  else if (n < 1200)
    return 3;
  else if (n < 1600)
    return 4;
  else if (n < 2000)
    return 5;
  else if (n < 2400)
    return 6;
  else if (n < 2800)
    return 7;
  else if (n < 3200)
    return 8;
  else
    return 0;
}
int main() {
  int color[9] = {0};
  int n, score;
  cin >> n;
  int cnt = 0;
  for (int i = 0; i < n; i++) {
    cin >> score;
    if (score >= 3200)
      cnt++;
    else
      color[getcolor(score)]++;
  }
  int ans = 0;
  for (int i = 1; i <= 8; i++) {
    if (color[i] != 0) ans++;
  }
  int min = ans;
  int max = ans + cnt;
  cout << min << " " << max << endl;
}
