Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Random cool shit you made thread.

Name: Anonymous 2008-06-04 10:39

GO!

Name: Anonymous 2008-06-04 14:33

>>20
Corrected version:

import Control.Monad.Identity

factorial n | n < 0     = fail "factorial: negative argument."
            | otherwise = return $ product [1..n]

fact = runIdentity . factorial

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List