
#![allow(unused)]

use std::cmp;
use std::io::{self, BufRead};
use std::iter;

macro_rules! destruct_ {
  ($e: expr, ()) => (
    assert!($e.next().is_none())
  );
  ($e: expr, ($arg: ident, $( $args: ident, )*)) => (
    $arg = $e.next().unwrap();
    destruct_!($e, ($($args,)*))
  );
  ($e: expr, ($arg: ident $(, $args: ident )*)) => (
    $arg = $e.next().unwrap();
    destruct_!($e, ($($args,)*))
  );
}

macro_rules! into {
  ($e: expr, $($name: ident)*) => {
    let mut iter = $e.into_iter();
    destruct_!(iter, ($($name)*));
  }
}

macro_rules! get {
  ($i: ident) => (
    let stdin = io::stdin();
    let mut $i = Vec::new();
    for line in stdin.lock().lines() {
      $i.push(
        line
          .unwrap()
          .split_whitespace()
          .map(|a| a.parse().unwrap())
          .collect()
      );
    }
  )
}

macro_rules! p {
  ($a: expr) => (
    println!("{:?}", $a);
  )
}

fn main() {
  let stdin = io::stdin();
  let mut args: Vec<Vec<i32>> = Vec::new();
  for line in stdin.lock().lines() {
    args.push(
      line
        .unwrap()
        .split_whitespace()
        .map(|a| a.parse().unwrap())
        .collect()
    );
  }

  let mut ls = [0; 9];
  for a in args[1].iter() {
    match *a as i32 {
      1...399 => ls[0] += 1,
      400...799 => ls[1] += 1,
      800...1199 => ls[2] += 1,
      1200...1599 => ls[3] += 1,
      1600...1999 => ls[4] += 1,
      2000...2399 => ls[5] += 1,
      2400...2799 => ls[6] += 1,
      2800...3199 => ls[7] += 1,
      _ => ls[8] += 1,
    }
  }

  let mut n = 0;
  let mut z = 0;
  for i in 0 .. ls.len() {
    if i == 8 {
      z = ls[i];
    } else if ls[i] > 0 {
      n += 1;
    }
  }

  println!("{} {}", n, n + z);
}
