Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void logNumbers() {
- int start = 1, end = 10;
- for (int index = start; index <= end; index++) {
- NSLog(@"%d", index);
- }
- }
- void logAlphabets() {
- int start = 65, end = 90;
- for (int index = start; index <= end; index++) {
- NSLog(@"%c", index);
- }
- }
- -(void) viewDidAppear:(BOOL)animated {
- [super viewDidAppear:animated];
- dispatch_queue_t aQueue;
- // Get the global concurrent queue.
- aQueue = dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0);
- dispatch_async_f(aQueue, NULL, logNumbers);
- dispatch_async_f(aQueue, NULL, logAlphabets);
- }
Advertisement
Add Comment
Please, Sign In to add comment