Create a project and make sure to save the cpp file with your name. 1. Write a full program that consists of the following 4 functions: a. Write a template function called "Min_Avg" that takes as...

Create a project and make sure to save the cpp file with your name. 1. Write a full program that consists of the following 4 functions: a. Write a template function called "Min_Avg" that takes as arguments 3 values. This function must:  Computes and displays the average of these 3 values.  Finds the minimum of these 3 values and returns it to main. b. Function main() that does the following:  Generate randomly three integers between 5 and 15 and displays them on the screen  Prompts the user to input three floats numbers  Call function "Min_Avg" and pass to it the 3 randomly generated integers  Call function "Min_Avg" and pass to it the 3 inputted floats numbers  Display the first two imputed float numbers  Call function "swap" and pass to it the first two imputed float numbers  Display again the first two imputed float numbers  Call function "Factorial" and pass to it the first randomly generated integer  Display the returned value from function "Factorial" c. Write the void function "swap" that takes as arguments 2 float numbers, this function swaps the values of the arguments passed to it and returns both of them to main. d. Write the recursive function "Factorial(num)" that takes a positive integer as argument, computes and returns its factorial value to main. Specify using a comment in your code where is the base case. Hint: The recursive relationship is: n! = n * (n–1)! And, the base case occurs when: 1! = 1
May 14, 2021
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here