
HP3-LESSON9-Version2
Authored by chien nguyen
Computers
6th - 7th Grade
Used 2+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
40 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the purpose of UITableViewDelegate and UITableViewDataSource in Swift?
To manage user interactions and data display in a UITableView
To handle networking requests
To manage UI animations
To create new view controllers
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the role of @IBOutlet weak var tableView: UITableView! in the code?
It creates a new UITableView instance
It connects the table view in the storyboard to the code
It declares a variable without initializing it
It assigns a weak reference to another view controller
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What type of data structure is listSound in the provided code?
Dictionary
Set
Array
Tuple
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the correct method to return the number of rows in a UITableView section?
func numberOfSections(in tableView: UITableView) -> Int
func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int
func numberOfRowsInSection(_ tableView: UITableView) -> Int
func tableView(numberOfRowsInSection section: Int) -> Int
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What function is responsible for creating and configuring each table view cell?
viewDidLoad()
didSelectRowAt indexPath:
cellForRowAt indexPath:
numberOfRowsInSection:
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Which method is automatically called when the view is loaded into memory?
viewDidLoad()
viewWillAppear()
viewDidAppear()
init()
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the file extension of a Swift source file?
.sw
.swift
.swiftx
.swi
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?