If I want to pop the last item from my NSMutableArray
would this be the most proper way?
id theObject = [myMutableArray objectAtIndex:myMutableArray.count-1];
[myMutableArray removeLastObject];
I'm sure someone from SOF has a better way.
If I want to pop the last item from my
I'm sure someone from SOF has a better way. |
||||
|
Retain it, delete it, use it, release it.
|
|||
|
There is no pop equivalent for NSMutableArray+Queue.h
NSMutableArray+Queue.m
Then import it and use it like this:
|
|||||||||||||
|
You can use That would save you a few keystrokes. If you want to be able to call it with a single line of code, you can wrap it all in a function or a category on |
|||
|