fun main(args: Array<String>) {
    val N = readLine()!!.toLong()
    var min = Long.MAX_VALUE
    repeat(5) {
        min = readLine()!!.toLong().coerceAtMost(min)
    }
    println(5 + (N + min - 1) / min - 1)
}