Conditional and Control Flow


#1

Set bool_four equal to the result of not not True or False and not True

The answer is False right ? But the compiler shows recheck the code

First not executes NOT NOT TRUE is "TRUE"
NOT true is "FALSE"
TRUE OR FALSE is " TRUE"
So Finally TRUE AND FALSE is "FALSE"

Where is the MISTAKE kindly help
TIA


#2

Please post your code.


#3


#4

Your code not what the ecxcercise wants you to do.


#5

@javablaster88281,
In this expression
not has highest precedence
and has 2nd highest
or has lowest of the 3

not not True or False and not True
#parenthesis expressing the precedence
(not (not True) or ( False and (not True))
(not   False  ) or ( False and    False  )
    True        or         False
               True

http://stackoverflow.com/questions/16679272/priority-of-the-logical-statements-not-and-or-in-python


#6


#7

The code shows up error when a given as TRUE


#8

Sorry WORKING FINE Thanks !!!


#9

Sorry WORKING FINE Thanks !!!