#include <iostream>
#include <algorithm>
using namespace std;

int main(){

  int n, i, num, max, min;
  int gray, brown, green, lightblue, blue, yellow, orange, red, tmp;
  gray = brown = green = lightblue = blue = yellow = orange = red = tmp = 0;

  cin >> n;
  for(i = 0; i < n; i++){
    cin >> num;
    if(num >= 1 && num <= 399){
      if(gray == 0) gray++;
    }else if(num >= 400 && num <= 799){
      if(brown == 0) brown++;
    }else if(num >= 800 && num <= 1199){
      if(green == 0) green++;
    }else if(num >= 1200 && num <= 1599){
      if(lightblue == 0) lightblue++;
    }else if(num >= 1600 && num <= 1999){
      if(blue == 0) blue++;
    }else if(num >= 2000 && num <= 2399){
      if(yellow == 0) yellow++;
    }else if(num >= 2400 && num <= 2799){
      if(orange == 0) orange++;
    }else if(num >= 2800 && num <= 3199){
      if(red == 0) red++;
    }else{
      tmp++;
    }
  }
  max = gray + brown + green + lightblue + blue + yellow + orange + red;
  min = gray + brown + green + lightblue + blue + yellow + orange + red;
  if(n <= 8 || (max == 0 && tmp >= 1){
    max += tmp;
  }else if(n > 8 && max == 0){
    max = 8;
  }
  if(min == 0 && tmp >= 1) min = 1;
  cout << min << " " << max << endl;
  return 0;
}
