Skip to content

Instantly share code, notes, and snippets.

@jgallagher
Created June 7, 2014 04:23
Show Gist options
  • Select an option

  • Save jgallagher/051a7cc5952add2a8c50 to your computer and use it in GitHub Desktop.

Select an option

Save jgallagher/051a7cc5952add2a8c50 to your computer and use it in GitHub Desktop.
extension Int : LogicValue {
func getLogicValue() -> Bool {
return self % 2 == 0
}
}
if !3 {
let x = "odd is false"
}
if 4 {
let x = "even is true"
}
@robrix
Copy link

robrix commented Oct 14, 2014

👏 I hereby award you the Evil Hack of the Moment Award™! ⭐

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment