klyn.collections.Array.lastIndexOf
method

    public native lastIndexOf(item as T, start as Int = -1) as Int

Description

Returns the last index of the given element.

    import klyn.collections

    values = f:[10, 20, 10]
    print(values.lastIndexOf(10))  # 2

Parameters

Parameter | Description
--- | ---
`item` | Element to search.
`start` | Zero-based index where the reverse search starts. `-1` starts at the end.

Returns

Last matching index, or `-1`.