Coder Social home page Coder Social logo

word_guessing_game's Introduction

Word Guesser Game

Introduction

This is a game in which the computer randomly chooses a word from different categories, and the user has to guess it. The user can guess the word by guessing the letters in the word. The user has as many chances as the number of letters in the word. The user can also ask for a hint, which will reveal a letter in the word. If the user can guess the word correctly, the user wins, otherwise the user loses.

Pre-requisit

This game doesn't need any special pre-requisit. It only needs a python interpreter to run.

Directory Structure

word_guesser_game
|-- src/
|  |-- main.py
|  |-- utils/
|  |  |-- word_generator.py
|  |  |-- hint_generator.py
|  |  |-- input_validator.py
|  |-- game_logic/
|-- README.md
|-- requirements.txt

How to Run

  1. Navidate to the root directory of the project (WORD_GUESSER_GAME).
  2. Add current directory to the python path.
    export PYTHONPATH="${PYTHONPATH}:$(pwd)"
    
  3. Run the game
    python main.py
    
  4. Follow on-screen prompts to play the game.

Modules

  • src/utils/: This directory contains the utility modules used in the game.
    • src/utils/word_generator.py: This module is used to generate random words from different categories.

    • src/utils/hint_generator.py: This module is used to generate hints for the user.

    • src/utils/input_validator.py: This module is used to validate the user input.

  • src/game_logic/: This directory contains the game logic modules.
  • src/main.py: This is the main module of the game. It contains the main function which is the entry point of the game. #test

word_guessing_game's People

Contributors

matthewhatami avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.