Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Shortened pattern in petals.

  • Loading branch information...
commit 78279da0a76fdce8076e4472c3baa55cbc65da74 1 parent d08ab3e
@barrucadu authored
Showing with 1 addition and 4 deletions.
  1. +1 −4 code/haskell/petals/petals.lhs
View
5 code/haskell/petals/petals.lhs
@@ -20,12 +20,9 @@ list of dice rolls.
> petals :: [Die] -> Int
> petals [] = 0
> petals (d:ds) = petals ds + case d of
-> One -> 0
-> Two -> 0
> Three -> 2
-> Four -> 0
> Five -> 4
-> Six -> 0
+> _ -> 0
Tying it all together
---------------------
Please sign in to comment.
Something went wrong with that request. Please try again.