diff options
author | Guillermo Ramos | 2012-05-08 17:41:55 +0200 |
---|---|---|
committer | Guillermo Ramos | 2012-05-08 17:41:55 +0200 |
commit | bedac58408e4c6a701dd8065ed7a11277f5358e5 (patch) | |
tree | 7d136b49e25c536712429ffd05fe99c947865c61 /scala/chores.scala | |
parent | b0ce25e6d3d77c18c958578fdbdae92654e46c93 (diff) | |
download | 7l-bedac58408e4c6a701dd8065ed7a11277f5358e5.tar.gz |
[Scala] Día 3
Diffstat (limited to 'scala/chores.scala')
-rw-r--r-- | scala/chores.scala | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/scala/chores.scala b/scala/chores.scala new file mode 100644 index 0000000..0e33b5f --- /dev/null +++ b/scala/chores.scala @@ -0,0 +1,8 @@ +def doChore(chore:String):String = chore match { + case "clean dishes" => "scrub, dry" + case "cook dinner" => "chop, sizzle" + case _ => "whine, complain" +} + +println(doChore("clean dishes")) +println(doChore("mow lawn")) |