Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Functors, Applicatives, and Monads in Pictures (2013). Parent comment
So we can have a function which takes a single parameter which is a tuple :
function_name :: (Param1Type, Param2Type) -> ReturnType
function_name :: Param1Type -> (Param2Type -> ReturnType)
function_name :: Param1Type -> Param2Type -> ReturnType
function_name :: (Param1Type -> Param2Type) -> ReturnType
There are no comments on this comment yet.
So we can have a function which takes a single parameter which is a tuple :
Or we can have a function which takes a single parameter and returns another function: Using implied operator precedence, the later is written: And has to be distinguished from a function which takes a function as parameter: