Yes, you're correct. Consider the case where you want to make a function
that returns a function. Perhaps you'd write:
```elm
makeMeAFunction : Int -> (Int -> Int)
makeMeAFunction i = (\j -> i)
```
If you call (makeMeAFunction 1), the result would be a function that takes
any integer and returns
It's because partial application.
You can pass the first int and Elm will return a function which needs just
one int (the second).
Using that returned function with the second int, finally will return the
third int.
--
You received this message because you are subscribed to the Google Groups "El
I have some confusion with the syntax in Elm, fully realizing that they may
have been modeled after Haskell and/or other languages.
Here's an example:
add : Int -> Int -> Int
Why wouldn't this be:
add : Int, Int ->
Is it because of partial application or currying?
--
You received this