Skip to content

Instantly share code, notes, and snippets.

@skyebook
Created May 31, 2016 16:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save skyebook/f33d50a268da2b674d5df645c1841db0 to your computer and use it in GitHub Desktop.
Save skyebook/f33d50a268da2b674d5df645c1841db0 to your computer and use it in GitHub Desktop.
extension Array {
func objectsAtIndexPaths(indexPaths: [NSIndexPath]) -> [Element] {
return indexPaths.map {self[$0.row]}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment