Declare a class named cuboids with its three data members


Q. What will be displayed on console for the following code segments when main function will be executed? [05j class Message protected:

string msg;
public:
string getMsg(void)
return msg;
void setMsg(string msg)
this->msg = msg;
};

class SMS : public Message string msg;
public:
string getMsg(void)
return Message::msg; void setMsg(string msg) Message::msg = this->msg;
int main(void)
Message .p_msg = new Message(); p_msg->setMsg("001,");

Question:

A cuboids is a three-dimensional shape having different measurements in each dimension say x, y and z. Cuboids shapes are often used for boxes, cupboards, rooms, buildings, etc. So keeping in the mind the importance of Cuboids you have to implement the following functionalities

a. Declare a class named Cuboids with its three data members of type float to have the measurements of the three dimensions.

b. Value should only ie assigned to the data members when it is greater than 0 and lesser than 35.00. Write all the set functions for each data member to set their values.

c. Implement default (sets all data members to 1), parameterized and copy constructor.

d. Provide a member function for taking the inputs for a particular object's data.

e. Overload assignment operator to assign the data of one object to another.

f. Overload stream insertion operator to display the data of object on the console.

g. Overload arithmetic addition (0) operator to return the result of two objects after addition.

Request for Solution File

Ask an Expert for Answer!!
Econometrics: Declare a class named cuboids with its three data members
Reference No:- TGS0964152

Expected delivery within 24 Hours