Skip to content

Instantly share code, notes, and snippets.

@kozross
Created November 8, 2020 22:22
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 kozross/c866e0fcf9736131ebf8548f425b3f69 to your computer and use it in GitHub Desktop.
Save kozross/c866e0fcf9736131ebf8548f425b3f69 to your computer and use it in GitHub Desktop.
module Guards where
doSomething :: Int -> Int
doSomething input
| input <= 10 && input >= 0 = doAThing
| input <= 20 && input >= 11 = doAnotherThing
| otherwise = doSomethingElseEntirely
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment