Question: 1 . Create a class named Cat. Declare two ( 2 ) empty instance variables: catType ( String ) and cutenessLvl ( int ) .
Create a class named Cat. Declare two empty instance variables: catType String and cutenessLvl int Create a public constructor without parameters. Inside the constructor, set the values of catType and cutenessLvl to "Unknown" and respectively. Add another public constructor with two parameters: type String and lvl int Inside the constructor, assign type to catType and level to cutenessLvl. Create an int type of method named getCuteness This method shall return the cat's cuteness level.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
