CPP - Assignment 4
Q1.
Create class Chair having following members.
data members:
int height
int weight
double price;
Color color (use enum for color)
member functions
parameterless Constructor
parameterized constructor
Input function
Display function
SetPrice function(static)
Destructor
Note: price must be shared by all the objects.
Q2.
Write a class stack. Implement stack using
array. Provide functions push,pop, isfull, isempty.
In main create the objectof stack and invoke its
method in menu driven way.
August 2024– January 2025 1
CPP - Assignment 4
Q3.
Alloctate memory dynamically for one
dimensional and two dimensional array by using
new operator
August 2024– January 2025 2