Possible Duplicate:
How can I compare two dates, return a number of days
I have two dates (as NSString in the form “yyyy-mm-dd”), for example:
NSString *start = "2010-11-01";
NSString *end = "2010-12-01";
I’d like to implement:
- (int)numberOfDaysBetween:(NSString *)startDate and:(NSString *)endDate {
}
componentsnow holds the difference.