Question: Do program 7 using C++ , using printf and scanf . Dont use cin and cout. Program 4: A slot machine has three windows. A

Do program 7 using C++ , using printf and scanf . Dont use cin and cout.
 Do program 7 using C++ , using printf and scanf .
Dont use cin and cout. Program 4: A slot machine has three

Program 4: A slot machine has three windows. A random fruit is picked for each window from cherry, apple, lemon, and orange. If all three windows match, the user wins 8 times the bet amount. If the first two windows only are cherries, the user wins 3 times the bet amount If the first window is a cherry and the second window is not a cherry, the user wins the bet amount Otherwise, the player loses their bet. Write a C program that will first allow the user to enter a bet amount. Next, the program should pick 3 random fruits for the 3 windows and print the 3 fruits picked. Lastly, the amount of money won or lost by the user should be displayed. Program 5: Write a C program which includes the following functions with parameter passing Function 1: Allow the user to enter 3 float values. Function 2: Print the 3 float values Function 3: Use the return statement to return the largest of the 3 float values. Print the largest value in the main. Function 4:Sort the 3 float values from low to high. Upon returning to the main, use your print function to print the 3 float values in sorted order Program 6: Rewrite Program 3 using appropriate functions and parameter passing. Also, please include a structure chart for your program which you can either create by hand or on the computer. Program 7: Rewrite Program 6 using a looping statement. You may use either a while loop, do loop, or for loop. Please include a brief statement in a comment statement in your program stating the assumptions you made to pick your looping statement That is, if the loop is deterministic or indeterministic and if the loop is entrance-controlled or exit-controlled Program 8: Write a C program that picks a random number from 1 to 50. Allow the user to guess the random number by printing if each guess is higher or lower than the random number. If the user cannot guess the random number in 6 guesses, print out the random number picked. If the user guesses the number in 6 or fewer guesses, print how many guesses it took the user to guess the random number Program9: Write a C program which uses the following functions for an array of 10 names: a. Load the array from the keyboard b. Print the array c. Sort the array in ascending order d. Print the array again using the same print function from b e. Allow the user to enter a full name and search for the name in the array. array or print "not found" if the name is not in the array Print "found if the name is in the

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!