module Main where
import Data.List
solve :: [Int] -> (Int,Int)
solve a =
    let list = [b `div` 400 | b <- a,b < 3200]
        ans = nub list
        list' = [b | b<-a,b>=3200]
    in (max 1 (length ans + length list'),max 1 (length ans + min (length list') 1))



main = do
    n <- getLine
    a <- (map read . words) <$> getLine 
    let ans = solve a
    print $ snd ans
    print $ fst ans
