class box{
public: double height, width, length;
box() {}; //Default constructor
box (double h, double w, double l) //with arguments
{height = h; width = w; length =l;};
double volume ()
{return height * width * length;}
};
class box_car : public railroad_car, private box {
public: box_car() : box (10.5, 9.5, 40.0){}; // Default constructor
}
Last modified at 8/5/97; 12:30:09 PM
Other Links of Interest
College of Computing | EduTech Institute | GVU Center
Mark Guzdial | Papers | CS 2390 Spring '97 Home Page | STABLE | MMC-CaMILE