let strNumbers : [String?] = ["1", "2", "3", nil] let numbers = strNumbers.compactMap{item in return Int(item)}