I’m reading chapter 12 about objects, especially this part :
NSDate *now = [[NSDate alloc] init]; NSLog(@"The new date lives at %p", now); NSLog(@"The date is %@", now); double seconds = [now timeIntervalSince1970]; NSLog(@"It has been %f seconds since the start of 1970.", seconds); NSDate *later = [now dateByAddingTimeInterval:100000]; NSLog(@"In 100.000 seconds, it will be %@.", later);
My question may be completely stupid, but here it is :
Would it be possible to define seconds as a pointer too ? (like *later)
Maybe not as an instance of NSDate class because it’s not really a date, but as an instance of NSObject for example ?
Because it’s also “filled” using an instance of a class and a date method.
Thanks for your comments !