how to determine when two NSDates are 1 week apart?

Posted by cgossain on Stack Overflow See other posts from Stack Overflow or by cgossain
Published on 2011-03-07T00:05:09Z Indexed on 2011/03/07 0:10 UTC
Read the original article Hit count: 176

I'm my app I have an NSMutableArray, and each entry has an NSMutableDictionary with several Key-Value pairs. One of these pairs contains the date of the entry. For one of the functions of my app I need to determine which entries are exactly 1 week apart from each other (i.e from Sunday to Saturday) and sum the data from one of the Key-Value pairs for each day of that week.

How should I go about doing this?

© Stack Overflow or respective owner

Related posts about iphone

Related posts about iphone-sdk-4.0