#include <bits/stdc++.h>
using namespace std;
int dx[4] = {1, -1, 0, 0};
int dy[4] = {0, 0, 1, -1};
int main() {
  std::ios::sync_with_stdio(false);
  std::cin.tie(0);
  int n;
  cin >> n;
  int color[9] = {};
  int mn = 0;
  int mx = 0;
  for (int i = 0; i < (n); i++) {
    int a;
    cin >> a;
    if (1 <= a && a < 400) color[0]++;
    if (400 <= a && a < 800) color[1]++;
    if (800 <= a && a < 1200) color[2]++;
    if (1200 <= a && a < 1600) color[3]++;
    if (1600 <= a && a < 2000) color[4]++;
    if (2000 <= a && a < 2400) color[5]++;
    if (2400 <= a && a < 2800) color[6]++;
    if (2800 <= a && a < 3200) color[7]++;
    if (3200 <= a) color[8]++;
  }
  for (int i = 0; i < (8); i++) {
    if (color[i] > 0) mn++;
  }
  mx = mn + color[8];
  cout << mn << " " << mx << "\n";
  return 0;
}
