#include <bits/stdc++.h>
using namespace std;
double PI = acos(-1);
int arr[10000005];
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  cout.tie(nullptr);
  int n, m, T, res;
  int maxi = -(1 << 30) - 1, mini = (1 << 30) - 1, count = 0, x = 0;
  int i, j, k;
  bool flag;
  string s1, s2;
  char s[100000];
  int ara[100005], ara2[100005];
  cin >> n;
  for (int i = (int)(0); i <= (int)(n - 1); i++) {
    cin >> m;
    if (m >= 1 && m <= 399)
      arr[0]++;
    else if (m >= 400 && m <= 799)
      arr[1]++;
    else if (m >= 800 && m <= 1199)
      arr[2]++;
    else if (m >= 1200 && m <= 1599)
      arr[3]++;
    else if (m >= 1600 && m <= 1999)
      arr[4]++;
    else if (m >= 2000 && m <= 2399)
      arr[5]++;
    else if (m >= 2400 && m <= 2799)
      arr[6]++;
    else if (m >= 2800 && m <= 3199)
      arr[7]++;
    else if (m >= 3200)
      x++;
  }
  for (int i = (int)(0); i <= (int)(7); i++) {
    count += (arr[i] != 0);
  }
  if (count)
    cout << count << " " << count + x << endl;
  else {
    cout << x << " " << x << endl;
  }
}
