I have an NSArray containing numbers as NSString objects. ie.
[array addObject:[NSString stringWithFormat:@"%d", 100]];
How do I sort the array numerically? Can I use compare:options
and specify NSNumericSearch
as NSStringCompareOptions
? Please give me an example/sample code.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…