Skip to content

Instantly share code, notes, and snippets.

@danielharan
Created March 26, 2009 21:41
Show Gist options
  • Save danielharan/86364 to your computer and use it in GitHub Desktop.
Save danielharan/86364 to your computer and use it in GitHub Desktop.
# FAIL
value = compute_value
value = (value > CONSTANT) ? value : CONSTANT
# WIN
value = [compute_value, CONSTANT].max
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment