mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2025-08-29 09:30:20 +02:00
Add simple NSSet example.
This commit is contained in:
@@ -146,6 +146,10 @@ int main (int argc, const char * argv[])
|
||||
[mutableSet addObject:@"Hello"];
|
||||
NSLog(@"%@", mutableSet); // prints => {(Hello)}
|
||||
|
||||
// Set object
|
||||
NSSet *set = [NSSet setWithObjects:@"Hello", @"Hello", @"World", nil];
|
||||
NSLog(@"%@", set); // prints => {(Hello, World)}
|
||||
|
||||
///////////////////////////////////////
|
||||
// Operators
|
||||
///////////////////////////////////////
|
||||
|
Reference in New Issue
Block a user