Question: Parents of the pupils of the Park Primary School must pay an amount for outfits for the annual play. All pupils take part in

Parents of the pupils of the Park Primary School must pay an 

Parents of the pupils of the Park Primary School must pay an amount for outfits for the annual play. All pupils take part in the play, except the Grade 0 pupils. The amount that the parents have to pay is calculated as follows: The cost of the outfits for Grade 1 and 2 pupils is R45. The cost of the outfits for Grades 3 to 5 is R65. Grade 6 and 7 pupils may play one or two roles. If they play a lead role, they may only play one role. The cost of the outfits is R70 if they play one role. If this role is a lead role, the cost is R100. If they play two roles, the cost is R130. Use a switch statement and write down ONLY the necessary C++ statements to calculate and display the amount to be paid or display an appropriate error message if required. Do NOT write a complete program. Use the following variables: int grade; int fee; bool lead role; //true if a child plays a lead role bool roles2; //true if a child plays 2 roles Assume that values have been assigned to these variables already.

Step by Step Solution

3.45 Rating (148 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

C CODE include using namespace std int main int grade6 int ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related General Management Questions!