https://kotlinlang.org logo
r

rocketraman

05/18/2018, 8:40 PM
I think the point is you can achieve what you want in different ways in Kotlin, without the pain of inheritance. For example, you could pass in a
PageCounter
function to the call site that understands how to count the number of pages in different types of books.