Skip to content

Instantly share code, notes, and snippets.

@Droogans
Last active August 29, 2015 14:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Droogans/6d497fb4993982303c37 to your computer and use it in GitHub Desktop.
Save Droogans/6d497fb4993982303c37 to your computer and use it in GitHub Desktop.
def is_negative(number):
return number < 0
def pos_neg(a, b, negative):
if negative:
return a < 0 and b < 0
return len(set(map(is_negative, [a, b]))) > 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment