How can we find the time format (whether 12 hours or 24 hours) mode in iPhone?

How can we find the time format (whether 12 hours or 24 hours) mode in iPhone?

Check this answer by Micheal Waterfall in this previous SO question Detect whether iPhone is displaying time in 12-Hour or 24-Hour Mode?
@implementation NSLocale (Misc)
- (BOOL)timeIs24HourFormat {
NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
[formatter setDateStyle:NSDateFormatterNoStyle];
[formatter setTimeStyle:NSDateFormatterShortStyle];
NSString *dateString = [formatter stringFromDate:[NSDate date]];
NSRange amRange = [dateString rangeOfString:[formatter AMSymbol]];
NSRange pmRange = [dateString rangeOfString:[formatter PMSymbol]];
BOOL is24Hour = amRange.location == NSNotFound && pmRange.location == NSNotFound;
[formatter release];
return is24Hour;
}
@end
Hope this helps