first
Modified on Mon, 07 Aug 2023
Description
Get the first element of an array.
Syntax
first(array)
Parameters
Input Parameter | Type | Description |
---|---|---|
array | Array | The array to query |
Return value
Type |
---|
any |
Sample
Example | Result | Description |
---|---|---|
first([1, 2, 3]) | 1 | Returns the first element |
To view all the List functions, click here.
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article