Boolean Operator Precedence | SoloLearn: Learn to code for FREE!

+2

Boolean Operator Precedence

The examples in this section are sort of vague. Are we interpreting this as (not 1) == 1, or as not (1 == 1)?

8/18/2016 2:15:39 AM

Taylor Street

5 Answers

New Answer

+2

(not 1) == 1 this is correct precedence. first unary operator comes then binary.

+2

Is 1 = 1 ?

0

Because the answer is same either way.

0

0

It is interpreted as not (1==1) first 1==1 implies True Then not(1==1) implies not(True) which is False