Home / Expert Answers / Computer Science / i-need-help-pa813

(Solved): I need help . ...



I need help . A quite different way of using sentinels is to write guessing games. The sentinel becomes the value you need to guess. The game should keep going until the user guesses the right value. Assume that right_value has been assigned an integer value between 0 and 100. Write a program with a loop that repeatedly reads the guesses until the input is the same as right_value. The program should let the player know if their guess is higher or lower than right_value. At the end, the program should display the number of guesses the player made. Note: Take a look at the sample run. Make sure your program's prompts and messages are the same. Sample Run (User input enclosed in <>) Enter a guess: <1> Your guess is too low. Enter a guess: <50> Your guess is too high. Enter a guess: <22> Your guess is too low. Enter a guess: <27> Correct! It took you 4 guesses.



We have an Answer from Expert

View Expert Answer

Expert Answer


We have an Answer from Expert

Buy This Answer $5

Place Order

We Provide Services Across The Globe