Simple, Quality, Awesome Software

Guess the Number!

Problem Description

Create a program where the computer picks a number between 1 and 100. (Use the Random class that was discussed in Chapter 17.)

Allow the user to enter a number (Chapter 8) and convert it to an int.

Compare their number against the one the computer chose. If it is too low or too high, tell the user. If it is correct, tell the user so and end the program.

Loop until the player guesses the correct number.

Solution

GuessTheNumber.zip