How to print the date in iphone?
I am new to iphone development.I am having array of date .I want to print the date in my console.But I didn't want to convert it into a string and print it.I want to print as a date.How can 开发者_开发百科i achieve that.Please help me out thanks.
NSLog(@"%@", [NSDate date]);
The %@
specifier can accept any ObjC objects. It will call -description
to convert it into a string automatically when printing.
精彩评论