#![allow(unused_macros)]

macro_rules! line {
    () => {{
        let mut buf = String::new();
        std::io::stdin().read_line(&mut buf).unwrap();
        buf
    }};
}
macro_rules! line_as_vec {
    ( $t:ty ) => {
        line!()
            .trim()
            .split_whitespace()
            .map(|x| x.parse().unwrap())
            .collect::<Vec<$t>>()
    };
}
macro_rules! line_parse {
    ( $( $i:ident : $t:ty ),* ) => {
        let ( $( $i ),* ) = match &line!().split_whitespace().collect::<Vec<_>>()[..] {
            &[ $( $i ),* ] => ( $( $i.parse::<$t>().unwrap() ),* ),
            _ => panic!(),
        };
    };
}

fn main() {
    line!();
    let a_vec = line_as_vec!(usize);

    let mut state = std::collections::HashMap::<usize, usize>::new();
    for a in a_vec {
        state
            .entry(std::cmp::min(a, 3200) / 400)
            .and_modify(|x| *x += 1)
            .or_insert(1);
    }

    let mut ans = (state.len(), state.len());
    if let Some(x) = state.get(&8) {
        ans.0 = std::cmp::max(1, ans.0 - 1);
        ans.1 = ans.1 - 1 + x;
    }

    println!("{} {}", ans.0, ans.1)
}
