import java.math.*

fun main(args: Array<String>) {
    val (Q, H, S, D) = readLine()!!.split(" ").map { it.toLong() }
    var N = readLine()!!.toLong() * 4L
    
    val qPrice = Q
    val hPrice = Math.min(qPrice * 2L, H)
    val sPrice = Math.min(hPrice * 2L, S)
    val dPrice = Math.min(sPrice * 2L, D)
    
    var ans = 0L
    
    ans += dPrice * (N / 8L)
    N %= 8L
    
    ans += sPrice * (N / 4L)
    N %= 4L
    
    ans += hPrice * (N / 2L)
    N %= 2L
    
    ans += qPrice * N

    println(ans)
}
