Reputation: 23
I have an assignment for a university course that I'm doing and I need assistance on why I'm getting this TypeError.
The original equation is: Surface Area = 3√(25 + 10√5) * 𝑎^2
a = input("Edge Length: ")
suface_area = (3 * math.sqrt(25 + (10 * math.sqrt(5)) (a) ** 2))
print(surface_area)
I expect the written code to give me an output of the calculated "Surface area" that this equation is supposed to provide me, however I keep getting the TypeError message when the program tries to execute the code.
Please give me feedback on what I should try to fix this. Thanks!
Upvotes: 1
Views: 45
Reputation: 16
Two tiny issues with your code is causing problems.
You're missing a *
in before (a)**2
in suface_area = (3 * math.sqrt(25 + (10 * math.sqrt(5)) (a) ** 2))
.
You misspelled the variable name suface_area
when your print
function is being told to printsurface_area
.
Hope this helps!
Upvotes: 0