objective 排序
NSMutableArray *sortedArray;
sortedArray = [array sortedArrayUsingComparator:^NSComparisonResult(id a, id b)
{ double first = [(People*)a getValueA];
double second = [(People*)b getValueA];
return second-first;
}];
更多:
http://iphone.xiaoxiaostudio.net/2012/11/20/%E5%A6%82%E4%BD%95%E7%BB%99nsmutablearray%E6%8E%92%E5%BA%8F/