import Control.Monad
import Data.Maybe
import qualified Data.ByteString.Char8 as BS
import Data.List

readInt = fst . fromJust . BS.readInt
readIntList = map readInt . BS.words
getInt = readInt <$> BS.getLine
getIntList = readIntList <$> BS.getLine

main = do
    [a,b,c,d] <- getIntList
    let x | a < 0 && 0 < b = [0,a,b]
          | otherwise = [a,b]
        y | c < 0 && 0 < d = [0,c,d]
          | otherwise = [c,d]
    let ans = maximum [s*t| s <- x, t <- y]
    print ans