fork download
  1. func (x,y,z) = x + y + z
  2. ff = curry func
  3.  
  4. main = do
  5. putStrLn $ "a BoT xyu " ++ show $ ff 1 2 3
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
[1 of 1] Compiling Main             ( prog.hs, prog.o )

prog.hs:2:12:
    Couldn't match type `(c, c, c)' with `(a, b)'
    Expected type: (a, b) -> c
      Actual type: (c, c, c) -> c
    Relevant bindings include ff :: a -> b -> c (bound at prog.hs:2:1)
    In the first argument of `curry', namely `func'
    In the expression: curry func

prog.hs:5:20:
    Couldn't match expected type `s0 -> String'
                with actual type `[Char]'
    The first argument of ($) takes one argument,
    but its type `[Char]' has none
    In the second argument of `($)', namely
      `"a BoT xyu " ++ show $ ff 1 2 3'
    In a stmt of a 'do' block:
      putStrLn $ "a BoT xyu " ++ show $ ff 1 2 3

prog.hs:5:36:
    Couldn't match expected type `[Char]'
                with actual type `a0 -> String'
    Probable cause: `show' is applied to too few arguments
    In the second argument of `(++)', namely `show'
    In the expression: "a BoT xyu " ++ show
stdout
Standard output is empty