
I don't think GHCi allows function and type definitions in interactive mode.
You have to write the functions in a source file and then load it. You can
then call the functions as usual.
Homero Cardoso de Almeida
On Thu, May 31, 2012 at 4:48 PM, Stan Kulp
I have been working my way through "Learn You a Haskell for Greater Good" and am stumped when I get to the "Syntax in Functions - Pattern Matching" section.
The book shows the following expression...
ghci> lucky :: (Integral a) => a -> **String
...but when I try to execute it in GHCi I get the following error...
<interactive>:1:1: Not in scope: `lucky'
What am I missing?
Stan Kulp 4421 W North Pinebrook Lane Columbia, MO 65203
Home: 573-234-2065 Work: 573-522-5075 Cell: 573-864-6051
_______________________________________________ Beginners mailing list Beginners@haskell.org http://www.haskell.org/mailman/listinfo/beginners