Answers for "check if x equals 0 python"

1

How to test multiple variables against a value?

x = 0
y = 1
z = 3

if 0 or 1 or 2 or 3 == x:
  print("This will not work")
if x == 0 or x == 1 or x == 2 or x == 3:
  print("This will work")
Posted by: Guest on December-15-2020

Code answers related to "check if x equals 0 python"

Python Answers by Framework

Browse Popular Code Answers by Language