Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

Python Quiz – Operators

Python Quiz Python Quiz


x = True

y = False

z = False



if x or y and z:

    print("yes")

else:

    print("no")



x = True

y = False

z = False



if not x or y:

    print(1)

elif not x or not y and z:

    print(2)

elif not x or y or not y and x:

    print(3)

else:

    print(4)

Python Quiz - Operators

After-Class Exercises

Python Quiz Python Quiz