Skip to main content

Array.get

getindexif_missing

Documentation

Gets an element from the array at a specified index (0-based). If the index is invalid then if_missing is returned.

Arguments

  • index: The location in the array to get the element from. The index is also allowed be negative, then the elements are indexed from the back of the array, i.e. -1 will correspond to the last element.
  • if_missing: The value to return if the index is out of bounds.