[python] Using the AND and NOT Operator in Python