import Control.Applicative

areaAndCirc :: Num a => [a] -> [a]
areaAndCirc [a, b] = [a*b, 2 * (a + b)]

getList :: Read a => IO [a]
getList = map read . words <$> getLine

main = putStrLn . unwords . map show . areaAndCirc . map read . words =<< getLine