Skip to content

tnngoan/Number-Guessing-Game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Number Guessing Game

  • A little HTML together with a pinch of Javascript and a tea spoon of CSS.

DEMO

Required Features 🎯

  • The following required functionalities are completed:

[ ] The user can attempt to guess a random integer between 1 and 100 by entering a value into a textbox. [ ] The user can press a button to check their guess, and receive feedback on whether their guess was too low, too high, or correct. [ ] After the user enters a guess, the textbox is cleared. [ ] The user sees feedback about the most recent guess in a Bootstrap alert class div. If the guess is correct, the user will see a div styled with the "success" background. [ ] The user sees feedback about the most recent guess in a Bootstrap alert class div. If the guess is incorrect, the user will see a div alerting the user whether the guess was too high, or too low. [ ] The user is limited to 5 guesses to guess the correct number, and can see the number of remaining guesses after each sincorrect guess via a "Guesses Remaining" area. [ ] The user can restart the game by pressing a "start over" button or link. The following optional features are implemented:

[ ] The user can see a history of past guesses. [ ] When the user guesses the same number twice, the user receives an error message alerting them to the fact that they've already guessed that number. The number of guesses remaining should not decrease. [ ] The user can play multiple rounds of the game, and see results about previous rounds on the screen. [ ] The user can see their best score of the session. Best score is defined as the round that took the fewest guesses to arrive at the correct number. [ ] The user can see how long it took to finish each round in seconds. [ ] The user is limited to 30 seconds per guess. If the user does not guess within the allotted time, the turn is lost.