Loading practice questions
What is a data class in Kotlin used for?
Correct Answer: C — To hold data without boilerplate code
Explanation:
A data class in Kotlin is designed to hold data. It automatically provides methods like toString(), equals(), hashCode(), and copy(), reducing boilerplate code.