冒泡
1.raywenderlinch iOS Interview Questions
- Explain method swizzling. When you would use it?
- 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.
- What happens when you invoke a method on a nil pointer?
-
Give two separate and independent reasons why
retainCount
should never be used in shipping code. - Explain your process for tracing and fixing a memory leak.
- Explain how an autorelease pool works at the runtime level.
- When dealing with property declarations, what is the difference between atomic and non-atomic?
- In C, how would you reverse a string as quickly as possible?
-
Which is faster: to iterate through an
NSArray
or anNSSet
? - Explain how code signing works.
- What is posing in Objective-C?
- List six instruments that are part of the standard.
-
What are the differences between
copy
andretain
? - What is the difference between frames and bounds?
-
What happens when the following code executes?
Ball *ball = [[[[Ball alloc] init] autorelease] autorelease];
- List the five iOS app states. — Almost no one gets this question right. Normally I have to give an example, such as background state, for them to know what I am talking about.
- Do you think this interview was a good representation of your skills as a developer?