#include <bits/stdc++.h>
using namespace std;
int main() {
  int N;
  cin >> N;
  map<int, int> cnt;
  for (int a; N--; ++cnt[min(a, 3200) / 400]) cin >> a;
  int x = cnt.size();
  int y = cnt[8];
  cout << x << ' ' << y + x - (y > 0 && x == 1) << endl;
}
