function main(data){
    input = data.split("\n");
    len = input[0];
    temp = input[1].split(" ");
    list = [];
    index = 0;
    for(var i = 0; i < len; i+=1){
        num = Math.floor(temp[i] / 400);
        if(num > 7){
            index += 1;
        }else if(list.indexOf(num) === -1){
            list.push(num);
        }
    }
    if(list.length === 0){
        console.log("%d %d", 1, index);
    }else{
        console.log("%d %d", list.length, list.length + index)
    }
}
main(require("fs").readFileSync("/dev/stdin", "utf8"));