npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

number_guessing_game-by-rehman

v1.0.1

Published

Guess Number Game is a command-line game that challenges your ability to guess a random number generated by the computer. It's a fun and simple game that can provide hours of entertainment. Try your luck and see if you can guess the correct number!

Downloads

5

Readme

Guess Number Game BY REHMAN

Guess Number Game is a command-line game that challenges your ability to guess a random number generated by the computer. It's a fun and simple game that can provide hours of entertainment. Try your luck and see if you can guess the correct number!

Features

  • Random Number Generation: The game generates a random number between 0 and 10, and your goal is to guess that number.

  • Multiple Rounds: You can choose the number of rounds you want to play. The game allows you to select either 3 or 5 rounds.

  • Interactive: The game interacts with you through a user-friendly command-line interface.

  • Winning: If you guess the correct number, you win the round and receive a congratulatory message.

  • Losing: If you don't guess the correct number in the allowed number of rounds, you'll be encouraged to try again later.

Installation

  1. Make sure you have Node.js installed on your computer.

  2. Clone this repository or download the source code.

  3. Open your terminal or command prompt and navigate to the project directory.

  4. Install the necessary dependencies using npm:

    npm install

Usage

  1. Run the game with the following command:

    node guess-number-game.js
  2. The game will start by greeting you and asking how many rounds you want to play (3 or 5 rounds).

  3. In each round, the game will prompt you to guess a number between 0 and 10.

  4. If you guess the correct number, you will receive a winning message and be informed about the generated number.

  5. If you don't guess the correct number within the allowed number of rounds, you'll be encouraged to try again later.

  6. You can run the game as many times as you like for more chances to win.

Example

Here's an example of playing a 3-round game:

Game Guess Number is starting!

Choose the total rounds:
1. 3
2. 5

? Choose the total rounds 3

round : 1
Guess a number between 0 and 10

? Enter a number 5
You are lower than the computer-generated number
Try Again

round : 2
Guess a number between 0 and 10

? Enter a number 8
You are higher than the computer-generated number
Try Again

round : 3
Guess a number between 0 and 10

? Enter a number 7
Congratulation! You are correct
The computer-generated number was 7
You Won, You can claim your reward

Author

The Guess Number Game program was developed by Abdul Rehman.

License

This program is made available under the [Abdulrehman] license.