Beginner
Kotlin
Q24 / 100
How do you declare default parameter values in Kotlin?
Correct! Well done.
Incorrect.
The correct answer is A) fun greet(name: String = "World")
A
Correct Answer
fun greet(name: String = "World")
Explanation
Kotlin supports default parameter values directly in the function signature, reducing the need for overloads.
Progress
24/100