insideSum :: (Float, Float) -> FloatinsideSum (a,b) = a + b sumTuple :: [(Float, Float)] -> FloatsumTuple [] = 0sumTuple (x:xs) = insideSum x + sumTuple xs main = insideSum(2.0,1.1)
Standard input is empty
[1 of 1] Compiling Main ( prog.hs, prog.o ) prog.hs:8:0: Couldn't match expected type `IO a' against inferred type `Float' In the first argument of `GHC.TopHandler.runMainIO', namely `main' When checking the type of the function `main'
Standard output is empty
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!