Hacker News new | ask | show | jobs
by leshow 3117 days ago
When I first start I though there was so MUCH syntax, (->), (<*>), (<$>), (>>=), (.), ($), etc

I realized pretty early on all these were just functions, that was cool experience for me. Even the types are sort of functions.

1 comments

One fun thing is how -> is basically just an infix operation that takes two types as arguments and returns a new type.

add :: (->) Int Int add x y = x + y

It's the function type, data (->) a b. It is commonly written in infix notation though.