Coders Packet

Number Guessing Game in Java

By Ashutosh Pandey

This is a short Java project that allows the user to guess the number generated by the computer. It stores the number of attempts the user takes to guess the right answer.

This is a short Java project that allows the user to guess the number generated by the computer. It stores the number of attempts the user takes to guess the right answer.

It takes the following steps:

  • The system generates a random number from a given range, say 1 to 100.
  • The user is prompted to enter their given number in a displayed dialog box.
  • The computer then tells if the entered number matches the guesses number or it is higher/lower than the generated number.
  • The game continues under the user guessing the number.

 

Download project

Reviews Report

Submitted by Ashutosh Pandey (Ashutoshpandey0911)

Download packets of source code on Coders Packet