Skip to content

Instantly share code, notes, and snippets.

@xcombelle
Created March 30, 2014 08:46
Show Gist options
  • Save xcombelle/9869757 to your computer and use it in GitHub Desktop.
Save xcombelle/9869757 to your computer and use it in GitHub Desktop.
>>> for age,name in itertools.product((21,22,23),("jim","toto")):
... print (age,name, (not (age > 22 or name == "jim")) == (age <=22 and name !="jim"))
...
21 jim True
21 toto True
22 jim True
22 toto True
23 jim True
23 toto True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment