githubEdit

ArrayFirst

Return first item in array

Method Signature

ArrayFirst(array=[array])

Arguments

Argument
Type
Required
Description
Default

array

array

true

The array to get the first item from.

Examples

Member Function

Use the member function to return the first item from an array

Run Examplearrow-up-right

someArray = [ 
	1,
	2,
	3,
	4
];
WriteOutput( someArray.first() );

Result: 1

Non-Member Function

Return the first item from an array

Run Examplearrow-up-right

Result: "Jerry"

Additional Examples

Last updated

Was this helpful?