Change the name

Report a typo

There is a class called Cat. This class has a private immutable field catName. Read the user input and write a function called changeName, which changes the value to the user input and returns it. Please notice that the function doesn't take any parameters and doesn't print anything.

Write a program in Kotlin
class Solution{

}
___

Create a free account to access the full topic