Difference between revisions of "Talk:Haskell Quiz/PP Pascal/Solution Ltriant"

From HaskellWiki
Jump to: navigation, search
(hint)
 
 
Line 10: Line 10:
 
mylength = genericLength
 
mylength = genericLength
 
</haskell>
 
</haskell>
  +
  +
----
  +
  +
Dammit, I knew there had to be a builtin function for it :( -Luke

Latest revision as of 04:01, 4 November 2006

mylength :: [a] -> Integer
mylength = toInteger . length

is the same as :

mylength :: [a] -> Integer
mylength = genericLength

Dammit, I knew there had to be a builtin function for it :( -Luke