Vidyalelo
Computer Science · Q44

Kotlin Programming MCQ for Competitive Exams, Interviews, and Certifications

Engineering and GATE · Computer Science · question 44

Q44

What is the purpose of the apply function in Kotlin?

A.
To perform a null-safe call on an object
B.
To apply a block of code to an object and return the object
Answer
C.
To filter a collection of objects
D.
To map a collection of objects to a different type

Answer: Option B

Solution

Answer: Option B
No explanation is given for this question Let's Discuss on Board