Question: class shape { public: vixtual string getName ( ) const f return Shape, } } : / / end class Shape class Circle : public

class shape {
public:
vixtual string getName() const f
return "Shape",
}}: // end class Shape
class Circle : public shape{
public:
Circle( double rad =0.0 I
radius = rad;
}
string getName () const (
return "Circle",
}
private:
double radius; // Circle's radius
};// end class Circle
Class rectangle: public shape
{ private:
Double lengt,width;
Public:
Rectangle(double1 double w){lengthd =1;
Width= w;}
String getName() const { return "recyangle";}
}; what si the uloupyt by the driver program?
 class shape { public: vixtual string getName() const f return "Shape",

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!