Created
January 15, 2011 21:47
-
-
Save seanparsons/781293 to your computer and use it in GitHub Desktop.
This file contains 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 intMatch(number: Int): String = { | |
return number match { | |
case 1 => "This is number 1." | |
case 2 => "This is number 2, it comes after 1." | |
case _ => "This number is neither 1 nor 2." | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment