Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
hikarudo
· 12y ago · 0 comments
(:) is a data constructor, not a type constructor, and its type is a -> [a] -> [a]. Examples of type constructors: [], Maybe, Either.
Comments
[–]
sold
12y ago
To be clear: [] can refer to two different entities, a data constructor (empty list) and a type constructor (the list type).
[–]
delluminatus
12y ago
Thanks for the clarification. You might be able to tell, that I am only in the first stages of trying to learn Haskell.