Why True of False ? Please i got stuck in this!


#1

**Emmm Guys, i’m so confused about this:
True or not False and False. not gets evaluated first, so we have True or True and False. and goes next, so we get True or False. As we’ve seen, True or False is True, so the value finally returned is True!

the Q is : why True or False ? why it is not True and False

Thank You so much for answering This Topic :blush:


#2

Same as with +-*/ operators. Evaluate them in order one at a time. (And note that some operators have precedence over overs, multiplication is carried out before addition.)


#3

from the right to left
not False and False = False
True or False= True :wink:


#4

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.