subject

Overview In this assignment, you will gain more practice with designing a program. Specifically, you will create pseudocode for a higher/lower game. This will give you practice designing a more complex program and allow you to see more of the benefits that designing before coding can offer. The higher/lower game will combine different programming constructs that you have been learning about, such as input and output, decision branching, and a loop. IT 140 Higher/Lower Game Sample Output Overview Maria has asked you to create a program that prompts the user to enter the lower bound and the upper hound. You have decided to write pseudocode to design the program before actually developing the code. When run, the program should ask the user to guess a number. If the number guessed is lower than the random number, the program should print out a message like "Nope, too low." if the number guessed is higher than the random number, print out a message like "Nope, too high." If the number guessed is the same as the random number, print out a message like "You got it!" Higher/Lower Game Description Your friend Maria has come to you and said that she has been playing the higher/lower game with her three-year-old daughter Bella. Maria tells Bella that she is thinking of a number between 1 and 10, and then Bella tries to guess the number. When Bella guesses a number, Maria tells her whether the number she is thinking of is higher or lower or if Bella guessed it. The game continues until Bella guesses the right number. As much as Maria likes playing the game with Bella, Bella is very excited to play the game all the time, Maria thought it would be great if you could create a program that allows Bella to play the game as much as she wants. Note: The output messages you include in your pseudocode may differ slightly from these samples. Sample Output Below is one sample output of the program, with the user input demonstrated by bold font. Prompt For this assignment, you will be designing pseudocode for a higher/lower game program. The higher/lower game program uses similar constructs to the game you will design and develop in Projects One and TWO. Welcome to the higher/lower game, Bella! Enter the lower bound: 10 Enter the upper bound: 30 Great, now guess a number between 10 and 30: 20 Nope, too low Guess another number: 25 Nope, too high Guess another number: 23 You got it! Below is another sample output of your program, with the user input demonstrated by bold font 1. Review the Higher/Lower Game Sample Output for more detailed examples of this game. As you read, consider the following questions: What are the different steps needed in this program? How can you break them down in a way that a computer can understand? What information would you need from the user at each point (inputs)? What information would you output to the user at each point? When might it be a good idea to use 'F' and "IF ELSE' statements? When might it be a good idea to use loop? 2. Create pseudocode that logically outlines each step of the game program so that it meets the following functionality: Prompts the user to input the lower bound and upper bound. Include input validation to ensure that the lower bound is less than the upper bound. - Generates a random number between the lower and upper bounds Prompts the user to input a guess between the lower and upper bounds. Include input validation to ensure that the user only enters values between the lower and upper bound. Prints an output statement based on the puessed number. Be sure to account for each of the following situations through the use of decision branching . What should the computer output if the user guesses a number that is too low? . What should the computer output if the user guesses a number that is too high? - What should the computer output if the user guesses the right number? Loops so that the game continues prompting the user for a new number until the user guesses the correct number. Welcome to the higher/lower game, Bella! Enter the lower bound: 10 Enter the upper bound: 5 The lower bound must be less than the upper bound. Enter the lower bound: 10 Enter the upper bound: 20 Great, now guess a number between 10 and 20: 25 Nope, too high Guess another number: 15 Nope, too low. Guess another number: 17 You got it! Sutrnil your completed pseudocode as a Word document of approximately 1 to 2 pages in length.

ansver
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 11:30, jcazares3558
Awell-diversified portfolio needs about 20-25 stocks from different categories.
Answers: 2
image
Computers and Technology, 24.06.2019 16:00, miner12924owhu4d
5.a fishing rod is formed from a composite material of 0.5 kg of glass fibers embedded in a matrix of 0.5 kg of epoxy resin. the glass fibers are assumed to be long, continuous and unidirectional. to achieve a greater stiffness it is proposed to use a different composite that is comprised of long continuous carbon fibers that will be embedded in a matrix of 0.5 kg of epoxy resin. if the modulus of elasticity of the carbon fiber composite is 10% greater than the elastic modulus of the glass fiber composite, estimate the mass of carbon fibers that will be used to make the carbon fiber composite. assume the applied tensile stress is parallel to the direction of the long axis of the fibers. the epoxy resin, glass fiber, and carbon fiber have an elastic modulus of 5, 86, and 350 gpa respectively and a density of 1100, 2500, and 1800 respectively.
Answers: 3
image
Computers and Technology, 24.06.2019 17:00, GreenHerbz206
What are some examples of what can be changed through options available in the font dialog box? check all that apply. font family italicizing bolding pasting drop shadow cutting character spacing special symbols
Answers: 2
image
Computers and Technology, 24.06.2019 22:00, apexdude2020
Need getting google account back, big issue
Answers: 2
You know the right answer?
Overview In this assignment, you will gain more practice with designing a program. Specifically, you...

Questions in other subjects:

Konu
Mathematics, 21.09.2020 08:01