z = eval(input())

a,b = z.split()





print((int(a)*int(b) ,2*(int(a)+int(b))))
a, b = list(map(int, input().split()))

print((str(a * b) + " " + str(2 * a + 2 * b)))

z = eval(input())
a, b = z.split()
print((int(a) * int(b), 2 * (int(a) + int(b))))

a, b = list(map(int, input().split()))
print((str(a * b) + " " + str(2 * a + 2 * b)))

-z = eval(input()) -a, b = z.split() -print((int(a) * int(b), 2 * (int(a) + int(b)))) +a, b = list(map(int, input().split())) +print((str(a * b) + " " + str(2 * a + 2 * b)))