ischer wrote:
From: Daniel Fischer
Subject: Re: [Haskell-cafe] Typing problem
To: haskell-cafe@haskell.org
Cc: "michael rice"
Date: Monday, January 31, 2011, 1:38 PM
On Monday 31 January 2011 18:29:59, michael rice wrote:
> I'm mapping a function over a list of data, where the map
Michael,
just leaving out the type declaration for 'normalize', your module
complies fine and ghc infers the following type:
normalize :: (Integral a, Floating a) => [a] -> a -> a
Note that the context (Integral a, Floating a) cannot be met by any of
the standard types. (try in ghci: ":i In
On Monday 31 January 2011 18:29:59, michael rice wrote:
> I'm mapping a function over a list of data, where the mapping function
> is determined from the data.
>
> g f l = map (g l) l
g f l = map (f l) l
probably
>
> So
>
> g serialize "prolog" -> [4,5,3,2,3,1]
>
> But I'm having typing proble
I'm mapping a function over a list of data, where the mapping function is
determined from the data.
g f l = map (g l) l
So
g serialize "prolog" -> [4,5,3,2,3,1]
But I'm having typing problems trying to do a similar thing with a function
that statistically normalizes data.
See:
http://people.