Write a program which calculates the area and perimeter of a given rectangle.
x = input()
x = x.split(" ")

width = float(x[0])
height = float(x[1])

area = width * height
perimeter = width * 2 + height * 2

print("{0} {1}".format(area, perimeter))
x = input()
x = x.split(" ")

width = int(x[0])
height = int(x[1])

area = width * height
perimeter = width * 2 + height * 2

print("{0} {1}".format(area, perimeter))