3. Write a C++ program that uses virtual functions to input,calculate, and display some quantities associated with a variety of2- and 3-dimensional objects. Design an abstract baseclass Shape from which you will derive classes Rectangle,Circle, Triangle, Box, Can, Cone, and Ball. The class Shape shouldcontain pure virtual functions Display,GetDimensions, Area, Perimeter, and Volume. For each of thederived classes, write member functions Display,GetDimensions, Area, Perimeter, and Volume that will do thefollowing:
- Display – output the type and dimensions for an object of theclass.
- GetDimensions – get the dimensions for an object of theclass.
- Perimeter – Calculate and display the perimeter of an object ofa
OROR