In this assignment, you are going to implement the hierarchy illustrated below: Wolf Werewolf Zombie Human Citizen Vampire Troll Nobbs Dwarf In this design, we have two base classes: Wolf and Citizen (Wolf will be an "IWolf" Interface if coding in C#) Wolf: There is no ability for multiple inheritance in C# so Werewolf will implement the Wolf Interface. If coding in C++, Werewolf will inherit from both Wolf and Citizen classes. Citizen has children: Human, Troll, and Dwarf Human has children: Werewolf, Zombie, Vampire, and Nobbs The Citizen class has the function pay taxes and speak, each subclass should implement differentiated versions. The Wolf base class will have some appropriate wolf like functionality such as Howl and Growl, which will be implemented in the Werewolf. The Werewolf will extend Human, but implement the IWolf interface for C#, and extend both Human and Wolf classes. Human's will pay their taxes in dollars, Trolls in gems, and Dwarfs in gold. Wolves do not pay taxes, but Werewolves will. Each constructor should indicate what is being created and destructor should indicate what is being destroyed. It would be helpful to have constructors accept a string with the name passed in so the constructor/destructor messages are more readable. The program (main) should involve the collection of taxes by one of the city's fine public servants. Create a single array of citizens and have each pay their taxes and speak. You can be creative and then proceed to showcase other functionality that you have included.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

Please create a code on c++ for this description. Include a flow chart aswell.

Components:

● Multiple files with classes organized. A well organized solution is critical.

● Implemented the above described functionality.

● Created a main function to showcase the different functions that were implemented along with a guide explaining what you are showing. 

In this assignment, you are going to implement the hierarchy illustrated below:
Wolf
Werewolf
Zombie
Human
Citizen
Vampire
Troll
Nobbs
Dwarf
In this design, we have two base classes: Wolf and Citizen (Wolf will be an "IWolf" Interface if
coding in C#)
Wolf: There is no ability for multiple inheritance in C# so Werewolf will implement the Wolf
Interface. If coding in C++, Werewolf will inherit from both Wolf and Citizen classes.
Citizen has children: Human, Troll, and Dwarf
Human has children: Werewolf, Zombie, Vampire, and Nobbs
The Citizen class has the function pay taxes and speak, each subclass should implement
differentiated versions.
The Wolf base class will have some appropriate wolf like functionality such as Howl and Growl,
which will be implemented in the Werewolf. The Werewolf will extend Human, but implement the
IWolf interface for C#, and extend both Human and Wolf classes.
Human's will pay their taxes in dollars, Trolls in gems, and Dwarfs in gold. Wolves do not pay
taxes, but Werewolves will.
Each constructor should indicate what is being created and destructor should indicate what is
being destroyed. It would be helpful to have constructors accept a string with the name passed
in so the constructor/destructor messages are more readable.
The program (main) should involve the collection of taxes by one of the city's fine public
servants. Create a single array of citizens and have each pay their taxes and speak. You can be
creative and then proceed to showcase other functionality that you have included.
Transcribed Image Text:In this assignment, you are going to implement the hierarchy illustrated below: Wolf Werewolf Zombie Human Citizen Vampire Troll Nobbs Dwarf In this design, we have two base classes: Wolf and Citizen (Wolf will be an "IWolf" Interface if coding in C#) Wolf: There is no ability for multiple inheritance in C# so Werewolf will implement the Wolf Interface. If coding in C++, Werewolf will inherit from both Wolf and Citizen classes. Citizen has children: Human, Troll, and Dwarf Human has children: Werewolf, Zombie, Vampire, and Nobbs The Citizen class has the function pay taxes and speak, each subclass should implement differentiated versions. The Wolf base class will have some appropriate wolf like functionality such as Howl and Growl, which will be implemented in the Werewolf. The Werewolf will extend Human, but implement the IWolf interface for C#, and extend both Human and Wolf classes. Human's will pay their taxes in dollars, Trolls in gems, and Dwarfs in gold. Wolves do not pay taxes, but Werewolves will. Each constructor should indicate what is being created and destructor should indicate what is being destroyed. It would be helpful to have constructors accept a string with the name passed in so the constructor/destructor messages are more readable. The program (main) should involve the collection of taxes by one of the city's fine public servants. Create a single array of citizens and have each pay their taxes and speak. You can be creative and then proceed to showcase other functionality that you have included.
Expert Solution
steps

Step by step

Solved in 4 steps with 5 images

Blurred answer
Knowledge Booster
Class
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education