use std::io::*;
use std::str::FromStr;

fn read<T: FromStr>() -> T {
    let stdin = stdin();
    let stdin = stdin.lock();
    let token: String = stdin
        .bytes()
        .map(|c| c.expect("filed to read char") as char)
        .skip_while(|c| c.is_whitespace())
        .take_while(|c| !c.is_whitespace())
        .collect();
    token.parse().ok().expect("failed to parse token")
}

fn main() {
    let n:usize = read();
    let mut arr = vec![0; 9];
    for _ in 0..n {
        let x:usize = read();
        match x {
            1..=399 => arr[0] = 1,
            400..=799 => arr[1] = 1,
            800..=1199 => arr[2] = 1,
            1200..=1599 => arr[3] = 1,
            1600..=1999 => arr[4] = 1,
            2000..=2399 => arr[5] = 1,
            2400..=2799 => arr[6] = 1,
            2800..=3199 => arr[7] = 1,
            _ => arr[8] += 1
        }
    }
    let ans:usize = arr.clone().into_iter().sum();
    println!("{} {}",ans-arr[8], ans);
}
