Sorting a NSArray

Posted by Yoot on Stack Overflow See other posts from Stack Overflow or by Yoot
Published on 2010-05-17T14:35:16Z Indexed on 2010/05/17 14:40 UTC
Read the original article Hit count: 261

Filed under:
|
|

Hi,

I have a NSArray of objects. Those objects have an int attribute called "distance". I would like to sort my array by distance.

Could someone please tell me how to do that ? I can't understand how the sortUsingSelector or sortUsingDescriptor methods are working...

Thanks

© Stack Overflow or respective owner

Related posts about nsarray

Related posts about sorting