So if I had an array of strings and I wanted to pull out all of the integers (as String
s), how could I do this?
For example:
myArray = ["1","2","3","unknown","bob"]
I've tried
myArray.filter { Int($0) }
But I get an error telling me I can't convert Int?
to Bool