iOS Interview Questions

Practice for iOS interviews by solving TestDome questions. Our interview questions are used by more than 5,000 companies and 450,000 individual test takers.

Jobseekers: Certify Your Knowledge

Take a Certification Test

Companies: Use Our Tests for Screening

Buy a Pack Of Candidates

Try to solve 4 iOS interview questions below. Hints can help you find answers to questions you are having trouble with.

1. UITableView

UI
   
Easy  

Select the components that are minimally required for constructing and configuring a UITableViewController, which can be used to view (but not manipulate) a list of items.

(Select all acceptable answers.)

UITableViewSource
UITableViewCell
UITableViewDelegate
UITableViewDataSource
UIViewController
   


2. View Controller

Event handling UI
   
Easy  

Which of the following statements are true for UIViewController?

(Select all acceptable answers.)

viewWillAppear will be called before a view appears on the screen.
viewDidRender will be called after a view renders on the screen.
viewWillDisappear is called after animations are configured.
When using storyboards, the controller is initialized with the init(coder:)/initWithCoder method.
View controllers manage a hierarchy of views.
   


3. Car

Swift
   
Easy  

Consider the following Swift definition of the structure Car:

struct Car {
    var color:UIColor?
    let model:String
    
    init(model:String) {
        self.model = model
        self.color = nil
    }

    mutating func changeColor(color:UIColor) {
        self.color = color
    }
}

Select the statements that are correct.

(Select all acceptable answers.)

The struct Car can be inherited from to create child structs.
The initializer init is required to set the initial values of all properties.
The property model cannot be changed after initialization.
The mutating keyword of changeColor is required to modify the instance variable color.
The changeColor function can set the property color to nil.
   


4. Events

Event handling
   
Easy  

Which of the following statements are true for user interface events in iOS?

(Select all acceptable answers.)

Touch up inside is an event provided by UIControl.
Drag and drop is a UIControl event.
Touch events can be cancelled.
Remote control events can be cancelled.
The first responder to an event can be changed.
The fast swipe event is provided by iOS.
Capturing swipe events is supported through a gesture recognizer.
   


If you feel ready, take one of our timed public iOS Interview Questions tests:
iOS

iOS Online Test (Easy)

Not exactly what you are looking for? Go to our For Jobseekers section.