Kotlin Program - Study Mode

[#231] What is the difference between a "var" and a "val" in Kotlin?
Correct Answer

(A) var is a mutable variable, while "val" is an immutable variable

[#232] What is the keyword used to define a companion object in Kotlin?
Correct Answer

(C) companion

[#233] What is the purpose of the "object" keyword in Kotlin?
Correct Answer

(A) To define a singleton object

[#234] What is the keyword used to define a constructor in Kotlin?
Correct Answer

(D) init

[#235] Which platform type is not targeted by Kotlin for application development?
Correct Answer

(D) None of these