Computer Science
Consider the given expression: not True and False or True
Which of the following will be correct output if the given expression is evaluated?
- True
- False
- None
- Null
Python Funda
8 Likes
Answer
True
Reason — The 'not' operator has the highest precedence, followed by 'and', which has precedence over 'or', and the evaluation proceeds from left to right.
not True and False or True
= False and False or True
= False or True
= True
Answered By
2 Likes