Question: My Assignment: This assignment involves writing a program that models a dog. A dog has a name, a breed (which may be unknown), a gender

My Assignment:

This assignment involves writing a program that models a dog. A dog has a name, a breed (which may be unknown), a gender (male or female), an age (in months), and a weight (in pounds). Anda dog may or may not have fleas. Dog behaviors include eating ( chomp chomp chomp ), barking ( woof woof woof ), and scratching fleas if a dog has any ( you can determine what this sound should be). Design a Dog class that models the attributes and behaviors described above. Provide appropriate class constructors, getter methods, setter methods, and any other methods you think are necessary to model a dog. When a dog object is created, in wont have fleas unless you specify otherwise, so youll need to use multiple constructors. Write a main method that creates at least two dogs and invokes their behaviors and displays their attributes.

Please keep this as simple as possible, thanks

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!