So I'm trying to code the hypotenuse theorem into python and for some reason even if I type the letter k when asking for the letter h, it continues as if I had entered h, even though it should take me to the else saying to try again.
print ("H for hypotenuse")
typ = input(":")
if typ == "H" or "h" or "Hypotenuse" or "hypotenuse":
print ("What Side are you missing?")
print("A for The leg, B for the base, C for The longest side")
side=(input(":"))
if side == "A" or "B" or "a" or "b":
if side == "A" or "a":
print("What is B?")
b = int(input(":"))
print("What is C?")
c = int(input(":"))
a = int((c*c)-(b*b))
a1 = (a/a)
print("A is ", a1)
else:
print("What is A?")
a = input(":")
print("What is C?")
c = input(":")
b = (c*c)-(a*a)
b1 = b/b
print("B is ", b1)
else:
print("What is A?")
a = input(":")
print("What is B?")
b = input(":")
c = (a*a)+(b*b)
c1 = c/c
print("C is ", c1)
else:
print ("Please try again")