Skip to content

Instantly share code, notes, and snippets.

@beezeebly
Created December 27, 2013 22:33
Show Gist options
  • Save beezeebly/8153584 to your computer and use it in GitHub Desktop.
Save beezeebly/8153584 to your computer and use it in GitHub Desktop.
Ruby logical operators
# && the AND operator
true && true # result true
true && false # result false
false && false # result false
# || the OR operator
true || true # result true
true || false # result true
false || false # result false
# ! the NOT operator
!true # result false
!false # result true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment