import java.util.Scanner

fun main(args: Array<String>) {
    val sc = Scanner(System.`in`)
    val h = sc.nextInt()
    val w = sc.nextInt()

    val hNum = sc.nextInt()
    val wNum = sc.nextInt()
    val count = h * w

    val row = hNum * w
    val column = wNum * h
    val dup = hNum * wNum
    val result = count - ((row + column) - dup)
    println(result)
}