#include <bits/stdc++.h>

using namespace std;

int main(void){
  int N;
  cin>>N;
  vector<int>vec(N);
  vector<int>color={0,0,0,0,0,0,0,0,0};
  for (int i=0;i<N;i++){
    cin>>vec.at(i);
  }
  for(x:vec){
    if(1<=x&&x<=399)color.at(0)=1;
    if(400<x&&x<=799)color.at(1)=1;
    if(800<=x&&x<=1199)color.at(2)=1;
    if(1200<=x&&x<=1599)color.at(3)=1;
    if(1600<=x&&x<=1999)color.at(4)=1;
    if(2000<=x&&x<=2399)color.at(5)=1;
    if(2400<=x&&x<=2799)color.at(6)=1;
    if(2800<=x&&x<=3199)color.at(7)=1;
    if(3200<=x)color.at(8)++;
 }
  int variety=0;
  for(int i=0;i<color.size()-1;i++){
    variety+=color.at(i);
  }
  variety=max(1,variety);
  //int select=color.size()-variety;
  /*if(select<color.at(7)){
    color.at(7)=select;
  }*/
  cout<<variety<<" "<<variety+color.at(8)<<endl;
  return 0;
}