if MyVariable == "abc":
print("Yes")
if (MyVariableA == "abc") and (MyVariableB >= 2.0):
print("Yes")
if MyVariable == 1:
print("Yes1")
elif MyVariable < 2:
print("Yes2")
elif (MyVariable < 3):
print("Yes3")
else:
print("No")
Boolean operators
NOT Equal
if not SomethingA == 2:
print("No")
if not(SomethingA == 2):
print("No")
Logical AND
if (SomethingA == 2) and (SomethingB == 4):
Logical OR
if (SomethingA == 2) or (SomethingB == 4):
Feel free to comment if you can add help to this page or point out issues and solutions you have found. I do not provide support on this site, if you need help with a problem head over to stack overflow.