query
On this page

head

lib.lists.head

Primop
Docs pulled from | This Revision | 21 minutes ago

Takes 1 arguments

list


Return the first element of a list; abort evaluation if the argument isn’t a list or is an empty list. You can test whether a list is empty by comparing it with [].


Noogle also knows

Aliases
Detected Type
head :: [a] -> a