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, 21.06.2019 16:40
Match each feature of e-publishing as an advantage, a disadvantage, a threat, or an opportunity. (choices) increased collaboration digitalized out-of-print versions monopoly over digital formats requirement for a specialized digital device pairs advantage of e-publishing disadvantage of e- opportunity for e- threat to e-
Answers: 1
question
Computers and Technology, 21.06.2019 17:20
Q-1 which of the following can exist as cloud-based it resources? a. physical serverb. virtual serverc. software programd. network device
Answers: 3
question
Computers and Technology, 22.06.2019 04:30
What kind of software users of all skill levels create web pages that include graphics, video, audio, animation, and other special effects? website authoring website software website publishing website editing
Answers: 1
question
Computers and Technology, 22.06.2019 20:00
What is the worst-case complexity of the maxrepeats function? assume that the longest string in the names array is at most 25 characters wide (i.e., string comparison can be treated as o( class namecounter { private: int* counts; int nc; string* names; int nn; public: namecounter (int ncounts, int nnames); int maxrepeats() const; }; int namecounter: : maxrepeats () { int maxcount = 0; for (int i = 0; i < nc; ++i) { int count = 1; for (int j = i+1; j < nc; ++j) { if (names[i] == names[j]) ++count; } maxcount = max(count, maxcount); } return maxcount; }
Answers: 3
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
Mathematics, 02.06.2022 02:40
question
Mathematics, 02.06.2022 04:30
question
Mathematics, 02.06.2022 06:50
question
Mathematics, 02.06.2022 07:10
question
Mathematics, 02.06.2022 08:20