Why Download Tutorial Reference

Lists

hd

Packagebios
Source file(native)
NatureFunction
Typefun list a1 -> a1

Usage

hd

Type
list a1 A list
a1 The first element of the list

Description

This function returns the first element of the list , or nil if is empty.

> hd 1:2:3:nil 
-> Int: 1 (0x3) 

Seen in

On the same topic