#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  int a[1000];
  int gray = 0;
  int br = 0;
  int gr = 0;
  int lb = 0;
  int bl = 0, ye = 0, ora = 0, re = 0, min = 0, max = 0, god = 0;
  cin >> n;
  for (int x = 0; x < n; ++x) cin >> a[x];
  for (int x = 0; x < n; ++x) {
    if (a[x] < 400 && gray == 0)
      gray = 1;
    else if (a[x] >= 400 && a[x] < 800 && br == 0)
      br = 1;
    else if (a[x] >= 800 && a[x] < 1200 && gr == 0)
      gr = 1;
    else if (a[x] >= 1200 && a[x] < 1600 && lb == 0)
      lb = 1;
    else if (a[x] >= 1600 && a[x] < 2000 && bl == 0)
      bl = 1;
    else if (a[x] >= 2000 && a[x] < 2400 && ye == 0)
      ye = 1;
    else if (a[x] >= 2400 && a[x] < 2800 && ora == 0)
      ora = 1;
    else if (a[x] >= 2800 && a[x] < 3200 && re == 0)
      re = 1;
    else if (a[x] >= 3200)
      god = god + 1;
  }
  min = gray + br + gr + lb + bl + ye + ora + re;
  max = gray + br + gr + lb + bl + ye + ora + re + god;
  if (min < 1) min = 1;
  if (max > 8) max = 8;
  cout << min << " " << max << endl;
  return 0;
}
