Kotlin HashSet contains()
Syntax & Examples


Syntax of HashSet.contains()

The syntax of HashSet.contains() function is:

fun contains(element: E): Boolean

This contains() function of HashSet checks if the specified element is contained in this collection.