Category to add subarray access using subscripts
Objective-C
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
NSArraySubarraySubscripts.xcodeproj
NSArraySubarraySubscripts
NSArraySubarrayTests
.gitignore
NSArray+Subarray.h
NSArray+Subarray.m
README.md

README.md

A category on NSArray that uses Object Subscripting to provide convinient access to subarrays.

Example usage:

NSArray *arr = [NSArray arrayWithObjects:@"Foo",@"Bar",@"Bob",@"Alice", nil];
NSLog(@"%@",arr[@"1..3"])
// will print (Bar, Bob, Alice)

More aboout object subscripting: