Question: C + + Functions 1 . ) Problem # 1 : Build a presidents ( ) function. Build a presidents ( ) function that prints

C++ Functions
1.) Problem #1: Build a presidents() function.
Build a presidents() function that prints out the names of the first 7 Presidents of the United States, each on a separate line. Have your main function call the presidents() function. Call your Project PresFunc, and store it on your Flash Drive.
2.) Problem #2: Build an avg() function.
Build an avg() function that takes 4 arguments and returns the average of these 4 numbers. Call your function from the main(). In main(), declare and set 4 varaibles, pass these variables to the avg() function, and then print the result. Do all this in main(). The function only figures the average. Call your project AvgFunc, and store it on your Flash Drive.
3.) Problem #3: Build a max() function.
Build a max() function that takes 3 arguments and returns the argument which is the highest. Call this function from the main(). In main(), declare and set 3 varaibles, pass these variables to the max() function, and then print the result. Do all this in main(). The function only figures the max. Call your project MaxFunc, and store it on your Flash Drive.

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 Programming Questions!