In most cases, number 2 is probably the best choice.
Number 1 has the ability to lose a release at some point for some reason, but for some reason it immediately frees an array that can be useful in memory environments.
Number 3 is basically the detailed equivalent of number 2, but it is useful if you want to use initWith *, which does not have a corresponding array with *.
Note. If you are hungry in memory, for example, in an expensive loop, where you need a fresh array for each iteration; Do not allocate or allocate new arrays; just use -removeAllObjects and recycle the array.
source share