a shape program that demonstrates the use of abstract class/methods…

Question Answered step-by-step a shape program that demonstrates the use of abstract class/methods…  a shape program that demonstrates the use of abstract class/methods and the Strategy Design Pattern. Each shape has a name and should be able to calculate its area and perimeter. You need to model Circles, Rectangles, Squares, and Right Triangles.Each shape can also be displayed on the screen. However, the display algorithm needs to be swappable.  Example: Suppose DisplayAlgoA displays an arbitrary shape as follows:{ name = xxxxx, area = xxxxxx, perimeter = xxxxxxx } DisplayAlgoB displays an arbitrary shape as follows: Shape: Area: xxxxxxxPerimeter: xxxxxxx You will need to print out and turn in your .h, .cpp, and output files that show your program working. Test it however you would like. In your testing, you should be able to demonstrate swapping the algorithms (like DisplayAlgoA, then print, then switch to DisplayAlgoB, then print again). Computer Science Engineering & Technology C++ Programming CS 1c Share QuestionEmailCopy link Comments (0)