I'm reading Learn You a Haskell, and in the monad chapters, it seems to me that ()
is being treated as a sort of "null" for every type. When I check the type of ()
in GHCi, I get
>> :t ()
() :: ()
which is an extremely confusing statement. It seems that ()
is a type all to itself. I'm confused as to how it fits into the language, and how it seems to be able to stand for any type.