Re: NSArray vs. NSSet
Re: NSArray vs. NSSet
- Subject: Re: NSArray vs. NSSet
- From: "Mike R. Manzano" <email@hidden>
- Date: Thu, 10 Mar 2005 11:50:53 -0800
Aha, I tricked you into answering my question :) Just kidding.
The question came up when I discovered there was an NSSet class,
coupled with the fact that I've gotten away with using nothing but
arrays and dictionaries in my code so far.
Anyway, back to your regularly scheduled programming.
Mike
On Mar 10, 2005, at 11:45 AM, Shawn Erickson wrote:
This a trick question? ;-) The answer is when NSSet is a better fit
for what you are doing then NSArray.
Review the docs for both classes and think about the difference on
what they do, for example one allows you to access items primarily by
index the other by object comparison, one is ordered the other isn't,
one allows duplicate objects in the collection the other doesn't, etc.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden