Example of filtering by key word
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Select nonchanging values like neighbordhoods - Good for buttons | |
let neighborhoods: NSArray = ["Crown Heights", "Clinton Hill", "Sunset Park"] | |
let fiteredNeighborhoods = (neighborhoods as! Array).filter { $0 == "Sunset Park" } | |
print(fiteredNeighborhoods) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment