vendredi 19 juin 2015

Three or more conditions in an "if" statement.. (Python)

I'm new to python and have been trying to find the answer to this for a couple of hours...

if three of my conditions are met, I want the program to do something.. however, this doesn't work:

       if variableA >= 3 and variableB <= 4 and variableC == 10:
          do_something

I can't iterate through anything because the three conditions that need to be met are unrelated.

much appreciated!

Aucun commentaire:

Enregistrer un commentaire