i need program

create a bace class called shape.usethis class to store two double type values that could be used to compute the area of figures.derive two specific classes called square and rectangle from the base class shape. member function display_area() to compute and display the area of figures.make display_area()
This isn't a homework service.
I think this article may help you understand inheritance some. Hint:: start off making both classes as usual. Now think, how can I use, not call, the functions of derived (since you already have to access to the base)... http://www.exforsys.com/tutorials/c-plus-plus/inheritance-an-introduction.html
Topic archived. No new replies allowed.