Kotlin Program - Study Mode
[#61] What keyword is used to define a nested class in Kotlin?
Correct Answer
(B) nested
[#62] Can an inner class have its own properties and methods?
Correct Answer
(D) Yes, it can have its own properties and methods just like any other class
[#63] How can an inner class access the outer class's properties and methods?
Correct Answer
(B) By using the "outer" keyword
[#64] What keyword is used to create an instance of an inner class in Kotlin?
Correct Answer
(B) new
[#65] How can you initialize variables in a primary constructor in Kotlin?
Correct Answer
(B) by using the val keyword