fun main(args : Array<String>) {
    val N = readLine()!!.toLong()
    val A = readLine()!!.toLong()
    val B = readLine()!!.toLong()
    val C = readLine()!!.toLong()
    val D = readLine()!!.toLong()
    val E = readLine()!!.toLong()

    val bottleneck = listOf(A, B, C ,D, E).min()!!
    val div = (N.toDouble() / bottleneck.toDouble())
    var bottleneckCount = Math.floor(div).toLong()
    if (N.mod(bottleneck) != 0L) {
        bottleneckCount++
    }
    val ans = 4 + bottleneckCount

    println(ans)
}