Question: ( iv ) Write a function In C + + , computePrice that receives two parameters: the first one is a character variable indicating the

(iv) Write a function In C++, computePrice that receives two parameters: the first one is a character variable indicating the size of the pizza (S,M or L) and the second an integer variable indicating the number of toppings on the pizza. It then computes the cost of the pizza and returns the cost as a floating point number according to the rules:
, Small pizza =R50+R5.50 per topping
, Medium pizza =R70+R6.50 per topping
, Large pizza =R90+R7.50 per topping
 (iv) Write a function In C++, computePrice that receives two parameters:

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock 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 Databases Questions!