subject

Design a class Parallelogram that contains two private data members: - double length, - double height. Parallelogram class should also have following public methods: - parameterized constructor, - a method to calculate area of parallelogram. Design another class Rectangle that inherits from Parallelogram (since a Rectangle is-a Parallelogram). Class Rectangle should have following public members: - parameterized constructor, - a method to calculate perimeter, - a method to tell if the Rectangle object is a Square. Develop a main function to fully test these two classes.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 00:30
Quic which one of the following is the most accurate definition of technology? a electronic tools that improve functionality b electronic tools that provide entertainment or practical value c any type of tool that serves a practical function d any type of tool that enhances communication
Answers: 1
question
Computers and Technology, 23.06.2019 06:40
What are the three uses of a screw?
Answers: 2
question
Computers and Technology, 23.06.2019 23:40
4. what is the reason for including the following code snippet in the header file animal.h? #ifndef animal_h #define animal_h class animal { public: animal(); animal(double new_area_hunt); void birth(); void hunt(double new_area_hunt); void death(); double get_area_hunt() const; private: double area_hunt; }; #endif
Answers: 3
question
Computers and Technology, 25.06.2019 05:40
How to make a negative number positive in excel
Answers: 3
You know the right answer?
Design a class Parallelogram that contains two private data members: - double length, - double heigh...
Questions
question
Mathematics, 03.01.2021 23:20
question
Mathematics, 03.01.2021 23:20
question
Arts, 03.01.2021 23:20
Questions on the website: 13722360