I need to do a conditional statement in Python with an operator (or, and) insert by the user. Example:
a = 1
b = 1
c = 1
operator = input("Type the operator: ")
if(a == b operator b == c):
print("Yes")
else:
print("No")
I know, I can do it using if inside if. But I wanna know other way to do it.