#include<stdio.h>

int main(){
int n,a,b,ct = 0,count = 0;
int flag[8] = {0,0,0,0,0,0,0,0}

scanf("%d",&n);
for(;n > 0;n--){
scanf("%d",&a);
if(a < 3200){flag[a /400] = 1;}
else{ct++;}
}
for(n = 0;n < 8;n++){
count += flag[n];
}
if(count != 0){a = count;}
else{a = 1;}
if(count + ct > 8){b = 8;}
else{b = count + ct;}
printf("%d %d\n",a,b);
return 0;
}
