mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2024-11-29 22:12:07 +03:00
Add simple NSSet example.
This commit is contained in:
parent
8bd91cb6e2
commit
ce770c61df
@ -146,6 +146,10 @@ int main (int argc, const char * argv[])
|
|||||||
[mutableSet addObject:@"Hello"];
|
[mutableSet addObject:@"Hello"];
|
||||||
NSLog(@"%@", mutableSet); // prints => {(Hello)}
|
NSLog(@"%@", mutableSet); // prints => {(Hello)}
|
||||||
|
|
||||||
|
// Set object
|
||||||
|
NSSet *set = [NSSet setWithObjects:@"Hello", @"Hello", @"World", nil];
|
||||||
|
NSLog(@"%@", set); // prints => {(Hello, World)}
|
||||||
|
|
||||||
///////////////////////////////////////
|
///////////////////////////////////////
|
||||||
// Operators
|
// Operators
|
||||||
///////////////////////////////////////
|
///////////////////////////////////////
|
||||||
|
Loading…
Reference in New Issue
Block a user