{-# LANGUAGE ScopedTypeVariables #-}

import           Data.Functor
import           Text.Printf

main :: IO ()
main = do
  [a :: Integer, b :: Integer] <- fmap read . words <$> getLine
  let area = a*b
  let perimeter = 2*(a+b)
  printf "%d %d\n" area perimeter

