For each of the exercises, you need to write an algorithm and pseudo-code, in a comment section of the source code (.cpp). The algorithm and pseudo-code can cover only the key portion of the solution. There is no need to write algorithms for trivial code. Some examples of algorithms are given at the end of this assignment.
Write an overloaded function Add( ) that takes two parameters of the same type. The possible types of the arguments are type double, int, and char array[ ]. (Hint: define three Add().)
Write a test driver and ask the user if he/she would like to add two doubles, two int, or two character arrays. In the case of adding two char arrays, just output the two arrays one after the other using two cout statements.
Write a program that will read up to 10 letters (characters) into an array and write the letters back to the screen in the reverse order. The program should prompt the user to input all values and can determine whether the input has ended by a punctuation mark such as ‘.’ (make sure that you’ll include meaningful and intuitive messages to the user).
For example, if the input is abcde, the output should be edcba. Include appropriate messaging (UI) to the user.
Write a program that asks a student for his/her grades assessing his/her C++ programming skills. The student gets a separate grade for each homework assignment and the lab exam associated with it. In order for the student to pass the class, he/she needs to achieve 50% or better in all possible “dimensions”, i.e.,
Assume that the student has been given 5 “sets” of homework assignments and lab exams, respectively, and that the scores are given in percentages.
The program should get input from the screen and do the following:
1 2 3 4 5
HW 100 90 80 100 100 BEST HW: 100 WORST HW: 80 AVG HW: 94
LAB 100 100 70 60 90 BEST LAB: 100 WORST LAB: 90 AVG LAB: 84
AVG 100 95 75 80 95 Overall: 89
(option 1) Congratulations! You passed the class!
(option 2) I’m sorry to inform you that you failed the class, because your performance in
was <50%. Try again next semester.