fun main(args: Array<String>) {
    val (H, W) = listOfLong()
    println(if (H == 1L || W == 1L) 1 else (H * W + 1) / 2)
}
fun next() = readLine()!!
fun listOfString() = next().split(" ")
fun listOfLong() = listOfString().map { java.lang.Long.parseLong(it) }
