• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Removing duplicates from NSMutableArray
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Removing duplicates from NSMutableArray


  • Subject: Re: Removing duplicates from NSMutableArray
  • From: Jeffrey Drake <email@hidden>
  • Date: Mon, 2 Dec 2002 20:25:11 -0800

I can think of the way I would do it without much thought:

Source and Destination (being empty)

while item = enumerate source:
if item not in destination:
addto destination

Of course convert that to your favorite language.


On Monday, December 2, 2002, at 02:05 PM, Jan Van Tol wrote:

What is the best way to filter out duplicate NSStrings from an NSMutableArray? I can think of one way I could probably do it, but it seems pretty inefficient. Any suggestions?

Thanks,

-Jan Van Tol
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.



Jeffrey Drake
http://ezdrake.com
ICQ: 8257536
AIM: jptdrake
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Removing duplicates from NSMutableArray (From: Jan Van Tol <email@hidden>)

  • Prev by Date: Re: Removing duplicates from NSMutableArray
  • Next by Date: Help with encodeObject: forKey:
  • Previous by thread: Re: Removing duplicates from NSMutableArray
  • Next by thread: Re: Removing duplicates from NSMutableArray
  • Index(es):
    • Date
    • Thread