Created
December 2, 2014 17:17
-
-
Save dthomas/045302f10150cbed3bff to your computer and use it in GitHub Desktop.
Range Matching in Elixir
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def grade(marks) do | |
| cond do | |
| marks in 91..100 -> "A+" | |
| marks in 81..90 -> "A" | |
| end | |
| end |
chrismccord
commented
Dec 2, 2014
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment