Question: Write a class rectangle (preferably .h and .cpp) that can be used in order to make the following code work correctly according to the comments.
- Write a class rectangle (preferably .h and .cpp) that can be used in order to make the following code work correctly according to the comments.
#include
#include
#include \"rectangle.h\"
using namespace std;
int main()
{
rectangle r1, r2, r3;
r1.setValues(12, 4); // sets the values of width and height
r2.setValues(6, 13);
r3.setValues(10, 7);
cout
cout
cout
cout
}
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
