toSet
fun <T> Array<out T>.toSet(): Set<T>
fun ShortArray.toSet(): Set<Short>
fun FloatArray.toSet(): Set<Float>
fun DoubleArray.toSet(): Set<Double>
fun BooleanArray.toSet(): Set<Boolean>
Returns a Set of all elements.
The returned set preserves the element iteration order of the original array.