This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSDateComponents *dateComponents = [[NSCalendar currentCalendar] components:NSCalendarUnitHour fromDate:[NSDate date]]; | |
if (dateComponents.hour >= 9 && dateComponents.hour < 21) | |
{ | |
// display local notifications | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (NSString *)stringFromCount:(NSUInteger)count | |
{ | |
NSString *days = nil; | |
NSUInteger modulo10 = count % 10; | |
if (modulo10 == 1) | |
{ | |
days = NSLocalizedString(@"день", nil); | |
} | |
if (modulo10 == 2 || modulo10 == 3 || modulo10 == 4) | |
{ |