Question: Question 3 Given the following program segment. #include void calculate (float, float &, float &); int main() { float a=10, b=0, c=0; calculate (a, b,




Question 3 Given the following program segment. #include void calculate (float, float &, float &); int main() { float a=10, b=0, c=0; calculate (a, b, c); cout N a. List three (3) local variables in the main() function. b. Identify the data type of parameter received by function calculate(). C. Identify the type of passing of parameter x. d. Identify the type of passing of parameter z. e. Show the output of the above program. Question 3 Given the following program segment. #include void calculate (float, float &, float &); int main() { float a=10, b=0, c=0; calculate (a, b, c); cout N a. List three (3) local variables in the main() function. b. Identify the data type of parameter received by function calculate(). C. Identify the type of passing of parameter x. d. Identify the type of passing of parameter z. e. Show the output of the above program. Question 5 Given the following main () function: int main() 1 double price, netprice: char sport_type cout > sport_type: cout > price; netprice - calPrice (sport_type, prices; displayPrice (net price return 0; > Write the function definitions for calPrice() and displayPrice() that are involved in the program. For function calPriced, you are required to calculate the net price after the discount given for the related type of sport. The discount will be given based on sport's type as stated in the following table Sport's type Discount T 20% of the original price B 10% of the original price 25% of the original price 10m