compare will provide you with an NSComparisonResult, which you can use to order material inside a tableView, such as NSOrderedSame, or NSOrderedAscending, etc.
isEqualTo is an NSObject method that should be extended to include subclasses, such as NSString (isEqualToString :), basically it compares the object with another object as you would expect it with content. [@ "d" isEqualTo: @ "d"] will return TRUE or 1
source share