wrong exemple to show Operator Precedence | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

wrong exemple to show Operator Precedence

Considering this first exemple in the course on Operator Precedence >>> False == False or True True >>> False == (False or True) False >>> (False == False) or True True To my opinion this exemple doesn't show that == is always above (performed before) 'or'. The exemples shows only that == and 'or' are equal or == is above 'or'. Only when you add this command below (by turning around the first command of the exemple) it turns out that == is indeed above (performed before) 'or': >>> print(True or False == False) True

10th Apr 2020, 4:17 PM
Valentin Steenstra
0 Answers