iOS Interview Questions and Answers
Experienced / Expert level questions & answers
Ques 1. What does KVO stand for?
KVO means key-value observing, which enables a controller to observe changes to property value.
Ques 2. Which is the application thread from where UIKit classes should be used?
Unless it’s stated, use UIKit classes only from your application’s main thread or main dispatch queue. This restriction applies in particular to classes derived from UIResponder or that require modifying the user interface of your app in some way.
Ques 3. What is TVMLKit?
TVMLKit serves as a bridge between TVML, JavaScript, and your native tvOS software. You can test TVMLKit JS and TVML files from inside your tvOS app using the TVMLKit framework. The JavaScript environment can be used to build TVML objects, styles, views, and view controllers.
Ques 4. What is Swift?
Swift is a modern programming language created by Apple for iOS, OS X, watchOS, and tvOS apps that combines the best of C and Objective-C, but without the C compatibility issues. Swift follows secure programming patterns while also incorporating modern features to make programming simpler, more versatile, and enjoyable. Swift is welcoming to novice programmers and feels familiar with Objective-C developers.
Ques 5. What is an NSError in Swift?
The NSError class is a Cocoa class. The knowledge about an error condition is encapsulated in an extendable, object-oriented manner by an NSError object. It includes a predefined error domain, a domain-specific error code, and a user details dictionary with application-specific data.
Ques 6. What is the difference between KVC and KVO?
- KVC (Key-Value Coding) is a method for accessing an object’s properties using strings at runtime rather than needing to know the property names statically at development time.
- KVO (Key-Value Observing) allows a controller or class to monitor changes in a property value. In KVO, an object may request to be informed of any adjustments to a particular property, and the observer is automatically notified if that property’s value changes.
Ques 7. What is the difference between retain and assign?
Retain creates a reference from one object to another and increases the retain count of the source object.
Assign creates a reference from one object to another without increasing the source’s retain count.
Ques 8. What is Dynamic Dispatch?
At runtime, Dynamic Dispatch determines which implementation of a polymorphic procedure, such as a method or a function, to call. This means that when we want to call our methods, such as object methods, we must use this syntax. Swift, on the other hand, does not use dynamic dispatch by default.
Ques 9. What is GCD?
The GCD stands for Grand Central Dispatch. It is a low-level API that allows you to manage multiple concurrent operations. It will assist you in increasing the responsiveness of your app by deferring computationally intensive tasks to the context. It’s a simpler concurrency model than locks and threads to deal with.
Ques 10. What are the advantages of the Realm framework?
- To handle all of the work, only a small amount of code is needed.
- Available in both Object C and Swift.
- SQLite and Core Data have slower performance.
- Database files can be shared easily between iOS and Android devices.
- There is no fee, no charge.
- There is no limit to the data amount that can be stored.
- Regardless of huge data sets or massive storage, consistent speed and consistency
Ques 11. What is SpriteKit and what is SceneKit?
SpriteKit is a platform for creating animated 2D objects quickly and easily.
SceneKit is a platform for 3D graphics rendering that was inherited from OS X.
SpriteKit, SceneKit, and Metal are expected to boost a new generation of mobile games that push the boundaries of what the powerful GPUs in iOS devices can do.
Ques 12. What are the three significant benefits of guard statement?
The benefits are:
- There are no nested if let statements
- An early exit out of the function using return or using break
- Guard statement safely unwrap optionals.
Ques 13. What is the use of application:willFinishLaunchingWithOptions and application:didFinishLaunchingWithOptions?
Both of these methods are present in AppDelegate.swift file and are used to add functionality to the App when the App is going to be launched.
Ques 14. What is a Responder chain?
A ResponderChain is a hierarchy of objects that have the chance of responding to the received events.
Most helpful rated by users:
- What does KVO stand for?
- Which is the application thread from where UIKit classes should be used?
- What is iOS?
Related differences
Related interview subjects
Mobile Computing interview questions and answers - Total 20 questions |
Xamarin interview questions and answers - Total 31 questions |
iOS interview questions and answers - Total 52 questions |
Ionic interview questions and answers - Total 32 questions |
Android interview questions and answers - Total 14 questions |