Operators


+ - *
** (twice for exponentiation)


assignment operators - += -+ *= /=


also -= *= /= **= %= //=


also //= and %=
bodmas applies


(5 > 3) and (4 < 3) 


(5 > 3) or (4 < 3) 


not(5 > 3) 


print(10 > 9)      # True 


not Operator

if not keep_looking(x, y): break 


1) What are Membership Operators?
Membership operators are used to test if a sequence is present in an object. The in and not in operators are examples of these:

x = ["apple", "banana"] 
print("banana" in x) # returns True

x = ["apple", "banana"]
print("pineapple" not in x) # returns True


© 2026 Better Solutions Limited. All Rights Reserved. © 2026 Better Solutions Limited TopPrevNext