import java.io.BufferedReader
import java.io.InputStreamReader
import java.io.PrintWriter

val br = BufferedReader(InputStreamReader(System.`in`))
val out = PrintWriter(System.out)

fun main() {
    br.use { out.use {
        solve()
        out.flush()
    } }
}

fun solve() {
    readInteger()
    val colorCount = IntArray(9)
    val aList = readIntegerList()
    for (a in aList) {
        when (a) {
            in 1..399 -> colorCount[0]++
            in 400..799 -> colorCount[1]++
            in 800..1199 -> colorCount[2]++
            in 1200..1599 -> colorCount[3]++
            in 1600..1999 -> colorCount[4]++
            in 2000..2399 -> colorCount[5]++
            in 2400..2799 -> colorCount[6]++
            in 2800..3199 -> colorCount[7]++
            else -> colorCount[8]++
        }
    }
    var min = colorCount.dropLast(1).count { it > 0 }
    val max = min + colorCount[8]
    if (min == 0 && max > 0) {
        min = 1
    }
    out.println("$min $max")
}

fun readInteger() = Integer.parseInt(br.readLine())
fun readLong() = java.lang.Long.parseLong(br.readLine())
fun readStringList() = br.readLine()!!.split(' ')
fun readIntegerList() = readStringList().map(Integer::parseInt)
fun readLongList() = readStringList().map(java.lang.Long::parseLong)
fun readDoubleList() = readStringList().map(java.lang.Double::parseDouble)
