public native indexOf(item as T, start as Int = 0) as Int
Returns the first index of the given value.
| Parameter | Description |
|---|---|
item | The value to search for. |
start | Zero-based index where the search starts. |
The first matching index, or -1.
values = i:[10, 20, 10] print(values.indexOf(10, 1)) # 2