Skip to content

Instantly share code, notes, and snippets.

@AdamSheaffer
Last active February 27, 2020 16:18
Show Gist options
  • Save AdamSheaffer/3b6058bf62fd587d71fefcc4e09b0fa0 to your computer and use it in GitHub Desktop.
Save AdamSheaffer/3b6058bf62fd587d71fefcc4e09b0fa0 to your computer and use it in GitHub Desktop.

Make a console application that creates a random number between 1 and 10 and gives the user 3 tries to correctly guess the number

RULES

  • The application should prompt the user to guess a number
  • If the number is correct, the application should print a success message and exit the program
  • If the number is not correct, the program should give them two more guesses
  • If the number is not correctly guessed after 3 tries, a message should be printed to the screen and the program should exit.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment