开发者

How to filter the objects of an array with another array

开发者 https://www.devze.com 2023-01-06 22:41 出处:网络
I have one NSMutableArray with 100 objects. This is original array. I have another array that contains 20 objects which are a开发者_如何学编程lso in the original array.

I have one NSMutableArray with 100 objects. This is original array.

I have another array that contains 20 objects which are a开发者_如何学编程lso in the original array.

I want to display the original array in the view controller minus the objects in the other array.

How can I remove the existing objects from original array?

we can add objects to an array with

[filteredListCount addObjectsFromArray: currencyArray];

Is there a similar method or idea to filter the original array with the second array?

Thanks


[originalArray removeObjectsInArray:existedObjects];


[filteredListCount removeObjectsInArray: currencyArray]

0

精彩评论

暂无评论...
验证码 换一张
取 消