Ad
Code
Diff
  • def rectangle(base, height):
        return f'The area of the rectangle is {base * height} and the perimeter is {(base * 2) + (height * 2)}'
    
    • def rectangle(base, height):
    • area = base * height
    • perimeter = (base * 2) + (height * 2)
    • return f'The area of the rectangle is {area} and the perimeter is {perimeter}'
    • return f'The area of the rectangle is {base * height} and the perimeter is {(base * 2) + (height * 2)}'