#include <bits/stdc++.h>
using namespace std;
const int INF = 1001001001;
int main() {
  int N;
  cin >> N;
  vector<int> v(N);
  map<string, int> mp;
  for (int i = 0; i < (int)(N); i++) cin >> v.at(i);
  int red_cnt = 0;
  for (int i = 0; i < (int)(N); i++) {
    if (v.at(i) < 400) {
      if (!mp.count("Hai")) mp["Hai"] = 1;
    } else if (v.at(i) < 800) {
      if (!mp.count("Cha")) mp["Cha"] = 1;
    } else if (v.at(i) < 1200) {
      if (!mp.count("Mi")) mp["Mi"] = 1;
    } else if (v.at(i) < 1600) {
      if (!mp.count("Miz")) mp["Miz"] = 1;
    } else if (v.at(i) < 2000) {
      if (!mp.count("Ao")) mp["Ao"] = 1;
    } else if (v.at(i) < 2400) {
      if (!mp.count("Ki")) mp["Ki"] = 1;
    } else if (v.at(i) < 2800) {
      if (!mp.count("Dai")) mp["Dai"] = 1;
    } else if (v.at(i) < 3200) {
      if (!mp.count("Aka")) mp["Aka"] = 1;
    } else {
      red_cnt++;
    }
  }
  int ans = mp.size() + red_cnt;
  if (red_cnt != 0)
    cout << mp.size() << " " << ans << endl;
  else
    cout << 1 << " " << ans << endl;
}
