import Control.Applicative
import Control.Monad


main :: IO ()
main = do
  [h, w] <- map read . words <$> getLine
  [hh, ww] <- map read . words <$> getLine

  print $ h * w - (hh * w) - (ww * h) + hh * ww