object Main extends App {
  def getLine(): (Int, Int) = {
    val input: String = scala.io.StdIn.readLine
    val ary = input.split(" ").map(_.toInt)
    (ary(0), ary(1))
  }

  val (w1, h1) = getLine()
  val (w2, h2) = getLine()

  val answer = (w1 - w2) * (h1 - h2)
  println(answer)
}