import Data.List.Split

main = do line <- getLine
          putStrLn . writeRect . calcRect . readRect $ line

readRect :: String -> [Int]
readRect x = map read $ splitOn " " x

calcRect :: [Int] -> [Int]
calcRect x = [a*b] ++ [2*(a+b)]
  where a = head x
        b = last x

writeRect :: [Int] -> String
writeRect x =
  show area ++ " " ++ show perimeter
  where area      = head x
        perimeter = last x