2

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

I have another array that contains 20 objects which are also 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

2 Answers 2

3
[originalArray removeObjectsInArray:existedObjects];
Sign up to request clarification or add additional context in comments.

Comments

1

[filteredListCount removeObjectsInArray: currencyArray]

1 Comment

kubi answered first. so his answer is correct. my browser didnt show new answer while i was writing my own answer..

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.