Question: Write the three separate C++ code that compiles correctly and is in different cpp files. Sorry, only have one question left to post, so I'm

Write the three separate C++ code that compiles correctly and is in different cpp files. Sorry, only have one question left to post, so I'm hoping to get help in one try.

One, for a function that receives an integer passed to it. The function, named halveNumber)(), should divide the integer by 2, then return the result (which may contain a decimal place).

Two, for a function that prompts the user to enter a character, then stores the user's response in a char variable. The function should return the character entered by the user. (The function will not have any actual arguments passed to it.) Name the function getChar().

Three, for a function that receives four integers. The function should calculate the average of the four integers, then return the result (which may contain a decimal place). Name the function calcAverage().

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!