Question: Write a C++ program: Create the ZooAnimal inheritance hierarchy shown below. Every animal in the hierarchy should have a char* data member called name .

Write a C++ program:

Create the ZooAnimal inheritance hierarchy shown below. Every animal in the hierarchy should have a char* data member called name. Every Bear, Koala or Panda should have an int data member called gestationPeriod. Every Fish or Shark should have a float data member called speed.

Hierarchy:

Write a C++ program: Create the ZooAnimal inheritance hierarchy shown below. Every

Every animal in the hierarchy should include a function called feedingTime() that prints out details of when an animal should be fed. The actual feeding time will be different for each animal but every animal should have a feeding time. Every type of bear should include a function called makenoise() that prints out the noise made by the animal. The actual noise made will be different for each type of bear. Fish do not make any noise.

Koala Bear Zoo Animal Panda Fish Shark

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!