
2 Jul
2014
2 Jul
'14
3:52 p.m.
Hi, I have the following function plotf :: Ploteable a => ([a] -> IO ()) -> (a -> a) -> [a] -> IO () plotf plot fn xs = plot $ map fn xs that compiles correctly, but when I use it with: plotf win sin [1..100::Double] -- where win :: [Double] -> IO () I'm geting the error: No instance for (Ploteable Double) arising from a use of ‘plotf’ In the expression: plotf win sin [1 .. 100 :: Double] In an equation for ‘it’: it = plotf win sin [1 .. 100 :: Double] What am I missing? Thanks! 50 Aniversario de la Cujae. Inaugurada por Fidel el 2 de diciembre de 1964 http://cujae.edu.cu