+ 1
kotlin abstract classes
Abstraction You decide to make the Component class abstract, since you are not going to create objects of that type. You also add a show() function to it that the derived classes need to override. For a Button, the show() function should output: "Showing a Button", while for an Image it should output: "Showing an Image".
1 Resposta
+ 3
This is the practice 32.2 in the Kotlin course.
You need to write the concrete implementation of the show function in both subclasses of Component.
override fun show() { ... }
And what is YOUR question?