if ([array count] == 0)
If the array is nil, it will also be 0, since nil displays 0; therefore, checking whether an array exists is not required.
In addition, you should not use array.count as suggested. This may work, but it is not a property, and will list everyone who reads your code nuts if they know the difference between the property and the method.
UPDATE: Yes, I know that years later the account is now officially owned.
Andy Riordan Oct. 18 '10 at 19:28 2010-10-18 19:28
source share