'use strict'
const main = (sdi) => {
  const s = sdi.split("\n");
  const h1 = s[0].split(" ")[0]-0;
  const w1 = s[0].split(" ")[1]-0;
  const h2 = s[1].split(" ")[0]-0;
  const w2 = s[1].split(" ")[1]-0;
  console.log((h1-h2)*(w1-w2));
}

main(require('fs').readFileSync('/dev/stdin', 'UTF-8'));