use std::str::FromStr;
use std::collections::HashMap;

fn get_one<T : FromStr>() -> T {
    let mut s = String::new();
    std::io::stdin().read_line(&mut s).ok();
    return s.trim().parse().ok().unwrap();
}

fn get_vec<T : FromStr>() -> Vec<T> {
    let mut s = String::new();
    std::io::stdin().read_line(&mut s).ok();
    return s.trim().split_whitespace().map(|e| e.parse().ok().unwrap()).collect();
}

fn main() {
    let n : usize = get_one();
    let v : Vec<i32> = get_vec();
    let mut map = HashMap::new();
    let mut eights = 0;
    for i in 0..n {
        let mut x = v[i] / 400;
        //println!("{}", x);
        if x < 8 {
            *map.entry(x).or_insert(0) = 1;
        }
        else {
            eights += 1;
        }
    }
    let mx = map.values().fold(0, |sm, k| sm+k);
    println!("{} {}", mx, mx+eights);
}
