Here is simple example of checking variable across multiple values:
var = "a"
if var == "a" or var == "b" or var == "c":
print("true")
else:
print("false")
After a small reseach, I found another, more advanced approach by Martijn Pieters:
var = "a"
if var in {"a", "b", "c"}:
print("true")
else:
print("false")
But also, in the link I posted above, it is stated that brackets are also acceptable:
if var in ("a", "b", "c"):
What is the difference between curly brackets {...}
and (...)
brackets here?
And if it is possible to answer, what is the best?