Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write a C++ program that performs the following: (15 points) Prints on screen a selection menu as follow: a. Calculations. b. cos (x) and
Write a C++ program that performs the following: (15 points) Prints on screen a selection menu as follow: a. Calculations. b. cos (x) and marks. (8 points) (6 points) (1 point) c. Exit. (marks will be distributed equally between the branches of each main point except the last branch) A.If user presses a or A, the following sub menu should be displayed: 1- If user presses 1, program should call a function that Count Vowels Characters: write a function which should read a set of characters from the keyboard until q is pressed. The program should count the occurrence of each of vowel characters (a, e, w, u and o.). (2 points) 2- If user presses 2, Write a code that will allow the user to enter three integers and order these integers from smallest to largest using functions. (Use function to enter the three integer numbers by the user and another function that receives the three integers and order them). (3 points) 3- If user presses 3, Max Odd Digit: program should call a function that receives an integer number and returns the max odd digit of this number as the following example: x=12675, max digit = 7). (2 points) 4- If user presses 4, Return to the main menu. (1 point) b.lf user presses b or B, the following sub menu should be displayed: 1- If user presses 1, program should call a function that solves cos(x): write a function which receives the degrees and prints out the result of cos (x)= 1 -x/2!+ x^/4! - x/6!...... (note that x in radians) (note that you should define a function to calculate the factorial and a function to calculate the power using recursion). (2 points) 2- If user presses 2, your program should allow the user to enter marks for M students and each. student has N marks. Your code should output the number of passed students. (i.e. the student is passed if his/her average >= 50 (average of N student marks) (and also your code should output the average marks of failed students. (3 points) 3- If user presses 3, Return to the main menu. (1 point) To Exit press e or E. (1 point)
Step by Step Solution
★★★★★
3.46 Rating (153 Votes )
There are 3 Steps involved in it
Step: 1
Code include using namespace std void countVowels function to count the vowels char c int a0 e0 i0 o0 u0 whiletrue cout tEnter character q for quit cin c ifc q c Q break else ifc a c A a else ifc e c ...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started