Write a program which calculates the area and perimeter of a given rectangle.
a = input().split(' ')
print(int(a[0])*int(a[1]), int(a[0]*2)+int(a[1])*2)


a = input().split(' ')
print(int(a[0])*int(a[1]), int(a[0])*2+int(a[1])*2)

