how to compare two NSMutableArray?

Maulik picture Maulik · May 26, 2011 · Viewed 14.3k times · Source

How can I compare two NSMutableArray ? if both are same than it should return true otherwise false.

Thanks...

Answer

visakh7 picture visakh7 · May 26, 2011
return ([array1 isEqualToArray:array2]);

returns YES if arrays are equal else returns NO