array.first Function |
The array.first function returns the first element (the head) of a given array.
array.first(ident);
ident | Required. The array to find the first element of |
The first (head) element of the given array.
$arr = array.new(2, 3, 4); PRINT array.first($arr); /* 2 */
array.add - add an element to the tail of an array
array.join - convert an array to a string by joining all the elements
array.last - get the last element of an array
array.new - create a new array
array.pop - remove and return the element at the head of the array
array.range - return a sub-array from a specified array
array.set_at - modify the data at a specified index of an array
array.get_at - retrieve the data at a specified index of an array
length - get the number of elements in an array