n = [int(i) for i in input().split()]

print(n[0]*n[1], 2*(n[0]+n[1]))
n = list(map(int, input().split()))

print(n[0] * n[1], 2 * (n[0] + n[1]))
n = [int(i) for i in input().split()]
print(n[0] * n[1], 2 * (n[0] + n[1]))

n = list(map(int, input().split()))
print(n[0] * n[1], 2 * (n[0] + n[1]))

-n = [int(i) for i in input().split()] +n = list(map(int, input().split()))