摘要: @implementation NSString(compare)-(NSComparisonResult)intCompare:(NSString *)other{ int myValue = [self floatValue]; int otherValue= [other floatValue]; if (myValue == otherValue) { return NSOrderedSame; } return (myValue < otherValue ? NSOrderedAscending : NSOrderedDes... 阅读全文
posted @ 2013-05-24 17:53 九勺吹雪 阅读(731) 评论(0) 推荐(0)
摘要: 1. Whenever you create an object in viewDidLoad (setting the reference count to 1), you should release the object in viewDidUnload.2. It is a good practice to set an object to nil after release, because by setting it to nil it avoids a lot of problems. Any time you call a method on a nil object, it 阅读全文
posted @ 2013-05-24 10:35 九勺吹雪 阅读(154) 评论(0) 推荐(0)