Im trying to get the area of a users choice of shape and I can't figure out what is wrong with it. There is an error on lines 40, 4, and 17 (Python)


#1

def main():
choice = input_choice()
x = userNum()
calculate(choice)

def input_choice():
return str(input("Find the area ‘1’ for a square ‘2’ for a circle and ‘3’ for a triangle: "))

def userNum():
return int(input("If square or equilateral triangle, what is the length of its side. If circle, what is its radius: "))

def calculate(choice):
if choice == “1”:
square()
elif choice == “2”:
circle()
elif choice == “3”:
triangle()
else:
print(“Invalid Choice.”)

def square(x):
Area = x ^ 2
print(“The area of the square is”, Area)

def circle(x):
Area = 3.14 * x ^ 2
print(“The area of the circle is”, Area)

def triangle(x):
import math
Area = Sqrt(3) / 4 * x ^ 2
print(“The area of the triangle is”, Area)
main()


#2

Exponentiation in Python uses the ** operator.