subject

A class named CafeService contains  Two data members i. e. the orderID and the price of food item(s) served by
 A no-argument constructor to initialize both data fields with default values of “ord#0”, 0.0
 A parameterized constructor to initialize all data fields with user-defined values
Derive a class named StaffService from the class CafeService that holds the following:
 Two data members i. e.
o serviceFee,
o the cabinNumber to which the service has been made
 A function named totalCharges that returns total cost of an order (including serviceFee + price of food item(s) served)
 A parameterized constructor, which requires arguments for all of its own data fields as well as for the data fields of base class
 A member function named display() to show all the details of an order including orderID, price, and totalCharges
In the main() function, instantiate an object of class StaffService object and test the implementation of both classes through this object.

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 08:00
Someone with this coz i don’t really know what i can choose, just pick whatever u want. homework - you need to choose a website that you like or use frequently. you must visit the website and discuss 6 different features/parts/aspects of the website that you think makes it good. (100 words)
Answers: 2
question
Computers and Technology, 24.06.2019 11:30
Why is body language an important factor in a business meeting
Answers: 1
question
Computers and Technology, 25.06.2019 01:30
If the average computer chip had 1,200 transistors per square inch in 1970, approximately how many transistors per square inch would one have in 1976? use moore's law to calculate your answer
Answers: 1
question
Computers and Technology, 25.06.2019 02:30
On the pie chart below, which “slice” represents 30% of the budget?
Answers: 2
You know the right answer?
A class named CafeService contains  Two data members i. e. the orderID and the price of food item...
Questions
question
English, 17.02.2022 22:30
question
Biology, 17.02.2022 22:30
Questions on the website: 13722361