Question: NEED HELP ON PROGRAMMING PROJECT 1, UNSURE ON HOW TO START IT. BELOW IS THE INSTRUCTION. Please complete #8, page 298 Math Tutor in

NEED HELP ON PROGRAMMING PROJECT 1, UNSURE ON HOW TO START IT. BELOW IS THE INSTRUCTION.

"

Please complete #8, page 298 "Math Tutor" in your textbook:

In order to complete this, you will need to back up and look at #17 in Chapter 3 and #11 in Chapter 4. But all I need is one program submitted. Please see the attached Programming Project_1 Notes. In those notes I have explained both the functional requirements of the program and given you some pseudo code to get you going. If you do not wish to see the pseudo code, you can stop reading at the yellow high-lighted area. It is well marked."

Programming Project #1 I think that the first important part of this assignment is to describe the functional requirements. Because this has been described over 3 chapters, we need to really understand where we are going before we write pseudocode. So, what do they want? A menu-driven arithmetic tutorial program for young children that does the following: Display a menu of choices: 1. Addition 2. Subtraction 3. Multiplication 4. Division 5. Quit This menu should repeat until the user chooses item 5. Input validation is required for the menu input. If they choose anything other than 1,2,3,4 or 5, they need to have an error message and the menu should display again. As many times as they input a wrong item, they have to have an error message and the menu displayed again. If they choose 1 Display two integer numbers to be added. Each number should be no more than 3 digits, for example: 247 + 129 Get the users answer. If answer is correct then display a positive message otherwise display the correct answer and a POLITE message that they got the wrong answer. If they choose 2 Display two positive integer numbers for a subtraction problem. Each number should be no more than 3 digits, for example: 339 - 130 Get the users answer. If answer is correct then..(same as above) If they choose 3 Same as above, except for multiplication. If they choose 4 Same as above, except for division. VERY IMPORTANT: make the numbers evenly divisible, for example: 999 / 3 =

If they choose 5 Exist the program. Remember that the menu has to keep circling around. Menu driven programs all work the same way!!. Thats whats so cool about them. You make one or you make a million. Same code. Remember, this program is for young children. Keep it easy. Keep the answers integers. Keep the output clean. It is a requirement of this program that you use functions. Random number generation was discussed in chapter 3, on pages 128 and 129. -----------------------------------------end functional requirements----------------------------------------------- IF YOU DO NOT WANT TO SEE THE PSEUDOCODE SUGGESTIONS, PLEASE STOP READING NOW. Heres some p-code to help you get going: prototype the functions main() do call displayMenu which returns users choice switch(choice) case 1: call additionProblem break; case 2: call subtractionProblem break; case 3: call multiplicationProblem break; case 4: call divisionProblem break case 5: say goodbe! break default: Display error message that valid menu input is only the numbers 1-5. end switch While (choice != 5) int Function displayMenu() Display the menu Get the users input Return users input void additionProblem() Use 1+ rand() % 1000 to grab the first number Use 1+ rand() % 1000 to grab the second number Display the numbers so it looks like an addition problem Get the users answer If (users answer is correct) then display Congratulations! Message Else display correct answer. void subtractionProblem() etc.. void multiplicationProblem() hint: try 1+rand() % 100 so the numbers are smaller void divisionProblem() hint: (notice this time I used 1 + rand() %10) a=1+rand()%10; b=1+rand()%10; c=a*b; z=c/b; display "what is: c / b"

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!