Computers and Technology
Computers and Technology, 11.10.2020 23:01, kiera2599

Write a Java program that generates a random number between 0 and 50. Then, the program prompts for guesses until the user is correct, or has made 10 wrong guesses. After each guess, the program indicates whether the guess was too high, too low, or correct. Once the round has ended, either by a correct guess or by using up the 10 guesses, the program displays the current status. Enter an integer number ( 0 to exit): 3241 3241 has 4 digits. Sum of digits of 3241 is 10. Enter an integer number ( 0 to exit): 264 264 has 3 digits. Sum of digits of 264 is 12. Enter an integer number ( 0 to exit): -12 -12 has 2 digits. Sum of digits of -12 is -3. Enter an integer number ( 0 to exit): 0 End. Enter a positive integer between 0 and 9: -3 Invalid input number. Enter a positive integer between 0 and 9: 15 Invalid input number. Enter a positive integer between 0 and 9: 5 0 !

answer
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 06:00, wbrandi118
What role do chromosomes play in inheritance?
Answers: 1
image
Computers and Technology, 22.06.2019 17:40, math31343
Gabe wants to move text from one document to another document. he should copy the text, paste the text, and open the new document highlight the text, select the cut command, move to the new document, make sure the cursor is in the correct location, and select the paste command select the save as command, navigate to the new document, and click save highlight the text, open the new document, and press ctrl and v
Answers: 1
image
Computers and Technology, 22.06.2019 20:00, manyah6189
Amanda needs to create an informative print brochure for her local library’s fundraiser dinner. what critical detail must she have before she starts designing the brochure?
Answers: 1
image
Computers and Technology, 22.06.2019 20:00, jayjay5246
What is the term for water wave that is created by an underwater earthquake
Answers: 1
Do you know the correct answer?
Write a Java program that generates a random number between 0 and 50. Then, the program prompts for...

Questions in other subjects: