Aug-01-2019, 11:10 AM
== and != are operators of equality.
not is a logical operator that revers the value of a logical variable.
For understanding a difference just try to change "==" to "is_equal" and "!=" to "is_not_equal" functions.
not is a logical operator that revers the value of a logical variable.
For understanding a difference just try to change "==" to "is_equal" and "!=" to "is_not_equal" functions.
def is_equal(a, b): return a == b def not_is_equal(a, b): return a != b