Wednesday, November 27, 2013

iOS Interview Questions

From: http://www.raywenderlich.com/53962/ios-interview-questions


1. Explain method swizzling. When you would use it?

2.Take three objects: a grandparent, parent and child. The grandparent retains the parent, the parent retains the child and the child retains the parent. The grandparent releases the parent. Explain what happens.

3. What happens when you invoke a method on a nil pointer?  

4. Give two separate and independent reasons why retainCount should never be used in shipping code.

5. Explain your process for tracing and fixing a memory leak.

6. Explain how an autorelease pool works at the runtime level.

7. When dealing with property declarations, what is the difference between atomic and non-atomic?

8. In C, how would you reverse a string as quickly as possible?

9. Which is faster: to iterate through an NSArray or an NSSet

10. Explain how code signing works.

11. What is posing in Objective-C?

12. List six instruments that are part of the standard.

13. What are the differences between copy and retain?

14. What is the difference between frames and bounds?

15. What happens when the following code executes? Ball *ball = [[[[Ball alloc] init] autorelease] autorelease];

16. List the five iOS app states.

17. Do you think this interview was a good representation of your skills as a developer?