-
Notifications
You must be signed in to change notification settings - Fork 0
Collections
Maciej Walczynski edited this page Oct 22, 2013
·
6 revisions
NSArray *names = @[@"Adam", @"Brittany", @"Charles", @"Diane", @"Eugene", @"Fannie", @"Gregory", @"Heather", @"Ishmael", @"Jennifer", @"Kenny", @"Lindsay", @"Marcus", @"Nina", @"Oscar", @"Paige"];- NSArray (show different ways to create), arrayWith... @[] etc.
- Enumerate the array
- for
- fast enumeration
- enumerate using block
- NSSet (differences to NSArray)
- unordered
- can't insert the same object twice
- better performance (hashes)
- Substract from an NSSet
- Create a class to put into the NSSet with methods
desciptionisEqualhash - Use the class to create a set of objects, try to see the difference
-
NSMutableOrderedSetNSArrayNSDictionary