I have a function declaration called e6. I need to replace undefined by some code and make it work.
e6 :: Int -> Int -> Int
e6 = undefined
I know for example
add :: Int -> Int -> Int
add a b = a + b
It takes parameters a and b then return a + b. But how can I write a function with no argument. I tried
e6 :: Int -> Int -> Int
e6 = 2 + 3
And it said:
No instance for (Num (Int -> Int -> Int)) arising from a use of '+'