#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  int i;
  vector<int> a(n);
  for (i = 0; i < n; i++) cin >> a[i];
  vector<bool> b(8);
  int cnt = 0;
  for (i = 0; i < n; i++) {
    if (a[i] >= 3200)
      cnt++;
    else if (a[i] >= 2800)
      b[0] = true;
    else if (a[i] >= 2400)
      b[1] = true;
    else if (a[i] >= 2000)
      b[2] = true;
    else if (a[i] >= 1600)
      b[3] = true;
    else if (a[i] >= 1200)
      b[4] = true;
    else if (a[i] >= 800)
      b[5] = true;
    else if (a[i] >= 400)
      b[6] = true;
    else if (a[i] >= 1)
      b[7] = true;
  }
  int cnt2 = 0;
  for (i = 0; i < 8; i++)
    if (b[i] == true) cnt2++;
  cout << cnt2 << "\n";
  if (cnt2 + cnt > 8)
    cout << 8 << "\n";
  else
    cout << cnt2 + cnt << "\n";
}
