const input = require('fs').readFileSync('/dev/stdin', 'UTF-8');

const rectangle = input => {
  const [length, width] = input.split(' ').map(val => Number(val));
  const area = length * width;
  const perimeter = (length + width) * 2;
  console.log([area, perimeter].join(' '));
};

rectangle(input);

