Boolean Operators - Quiz

1. What is the output of the following Python code snippet?

if True or False: print("Yes") else: print("No")
None
Error
No
Yes

2. In Python, what does the following code print?

if not True: print("A") elif not (1 + 1 == 3): print("B") else: print("C")
B
C
Error
A

Log in or sign-up to access the quiz



Don't have a login?

You can still revise this topic