欢迎选择我的课程,让我们一起见证您的进步~~
penguin.setHealth(input.nextInt())
The set method is a return value of void type. The penguin.setHealth() method will not return a field. How can it perform an assignment operation?
penguin.setHealth(input.nextInt())
The set method is a return value of void type. The penguin.setHealth() method will not return a field. How can it perform an assignment operation?