0
Is possible to convert Array to Set to use contains syntax(for string) in SWIFT ?
For example I have: array1 = [1, 2, 4, 6] array2= [11,2, 45, 100 , 999] I want to quit duplicates :)
1 Answer
0
Assuming it is removing duplicates across the two arrays? Try
var s = Set(array1)
s = s.union(array2)