area :: Int->Int->Int
area a b= a*b

perimeter ::Int->Int->Int
perimeter a b= 2*(a+b)


main ::IO()
main = do
  s<-getLine
  let a:b:_=map (\x -> read x ::Int) (words s)
  putStrLn ((show (area a b))++" "++(show (perimeter a b)))
