# this program calculates perimeter and area of different shapes print (" this program calculates perimeter and area of different shapes") import math shape = input("choose a shape from square , rectangle or circle") if shape == "square": side = float(input("Enter the length of a side")) square_perimeter = side*4 square_area = side**2 print(f"The perimeter of a square with a length of {side} = {square_perimeter} the area = {square_area}") print("Square") elif shape == "rectangle": side = float(input("Enter the length of a side")) width = float(input("Enter the width of a side")) rectangle_perimeter = side*2 + width*2 rectangle_area = side*width print(f"The perimeter of a rectangle with a length of {side} and a width of {width} = {rectangle_perimeter} the area = {rectangle_area}") print("rectangle") else: shape == "circle"