firstOrNull
Returns the first element, or null
if the array is empty.
Since Kotlin
1.0Returns the first element matching the given predicate, or null
if element was not found.
Since Kotlin
1.0Returns the first element, or null
if the collection is empty.
Since Kotlin
1.0Returns the first element, or null
if the list is empty.
Since Kotlin
1.0Returns the first element, or null
if the array is empty.
Since Kotlin
1.3Returns the first element matching the given predicate, or null
if element was not found.