(function(stdin) {
	var lines = stdin.toString().split('\n');
        var a = parseInt(lines[0],10);
        var b = parseInt(lines[1],10);
        console.log(a * b);
        console.log(a + b * 2);
}(require('fs').readFileSync('/dev/stdin', 'utf8')));