``` // Copied from kotlin.collections public fun &...
# announcements
d
Copy code
// Copied from kotlin.collections
public fun <T> Iterable<T>.contains2(element: T): Boolean {
    if (this is Collection)
        return contains(element)
    return indexOf(element) >= 0
}
emptyList<Int>().contains("") // Error
emptyList<Int>().contains2("") // No error 👈 Why?