Question: Question-6: We want to write a program that implements the guess-the-number game. A secret number (say 71) is defined as a constant in the program.

Question-6: We want to write a program that implements the guess-the-number game. A secret number (say 71) is defined as a constant in the program. In the game, the player has to guess a secret number between 0 and 100. The user keeps entering a given number if it matches the secret number the program displays Congratulation!! otherwise it displays the message Lower if the number entered is larger than secret number, Higher otherwise. The program should display Sorry, try another time and terminates after 10 unsuccessful attempts. A C++ PROGRAM

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!