#include <bits/stdc++.h>
using namespace std;
int main() {
  int N;
  cin >> N;
  bool color[8] = {false};
  int tmp = 0;
  for (int i = 0; i < N; ++i) {
    int a;
    cin >> a;
    if (3200 <= a)
      tmp++;
    else if (2800 <= a)
      color[7] = true;
    else if (2400 <= a)
      color[6] = true;
    else if (2000 <= a)
      color[5] = true;
    else if (1600 <= a)
      color[4] = true;
    else if (1200 <= a)
      color[3] = true;
    else if (800 <= a)
      color[2] = true;
    else if (400 <= a)
      color[1] = true;
    else
      color[0] = true;
  }
  int ans = 0;
  for (int i = 0; i < 8; ++i) {
    if (color[i] == true) ans++;
  }
  cout << ans << " " << ans + tmp << endl;
  return 0;
}
