Created
September 21, 2012 14:26
-
-
Save thechrisoshow/3761746 to your computer and use it in GitHub Desktop.
New literal subscripting in objective c
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSArray *anArray = @[a,b,c]; | |
NSDictionary *aDictionary @{ a : a1, b : b1}; | |
// New subscripting format | |
anArray[0]; // => returns a | |
aDictionary[a] // => returns a1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment