//300
fun a019(args: Array<String>) {
    val (Q, H, S, D) = args[0].split(" ").map { it.toLong() }
    val N = args[1].toLong()
    var price: Long = 0

    if (D <= 2 * S && D <= 4 * H && D <= 8 * Q) {
        price += (N / 2) * D
        if (N % 2 == 1L) {
            if (S <= 2 * H && S <= 4 * Q) {
                price += S
            } else if (2 * H <= S && H <= 2 * Q) {
                price += 2 * H
            } else {
                price += 4 * Q
            }
        }
    } else if (2 * S <= D && S <= 2 * H && S <= 4 * Q) {
        price += N * S
    } else if (4 * H <= D && 2 * H <= S && H <= 2 * Q) {
        price += N * 2 * H
    } else {
        price += N * 4 * Q
    }
    println(price)
}

fun main(args: Array<String>) {
    a019(readLineList())
}

fun readLineList(): Array<String> {
    val lineList = mutableListOf<String>()
    while (true) {
        val line = readLine()
        if (line.isNullOrBlank()) {
            break
        } else {
            lineList.add(line!!)
        }
    }
    return lineList.toTypedArray()
}