
Roelof Wobben
After a short holiday I now studying chapter 6 of this book.
For the first exercise I have to make the function for ^ for postitive numbers.
I assume you mean the exponentiation function, and the only real indication for that is the solution you quoted later in your post. To help us help, you really should work on your problem descriptions.
Step 1 : Defining the type
^ :: [Int] -> Int
First of all, you have to learn proper Haskell syntax. Your type signature is invalid. But let me rewrite your type signature to correct syntax: (^) :: [Int] -> Int This is the type signature for a function (^), which expects exactly one argument, a list. Is this really what you want? Before going any further, you should come up with the right type signature for your function. Once you have that, we will continue. Greets, Ertugrul -- nightmare = unsafePerformIO (getWrongWife >>= sex) http://ertes.de/