Giter VIP home page Giter VIP logo

cs50p-final-project's Introduction

CS50P-Final-Project

The Final Project of the CS50P online course – the console version of the Wordle game

Description

This is a final project for HarvardX CS50P course (CS50's Introduction to Programming with Python). This terminal version of the Wordle game was made by Vasilisa Chebotareva.

In this game you should guess the 5-letter word in 6 tries. The word is a singular noun, where letters can be repeated.

After every attempt the user sees colored guess distribution.

  • If the letter is in the word and in the right spot, it turns green 🟩
  • If the letter is in the word but in the wrong spot, it turns yellow 🟨
  • If the letter is not in the word, it turns white ⬜

In this program I tried to prevent potential mistakes and added some features.

  1. A target word (which user should guess) is picked randomly from the .txt file with 5-letter nouns.
  2. The user's guess word is checked to be a 5-letter word.
  3. The user's guess word is checked to be a singular noun in Free Dictionary API.
  4. Identical letters in words are controlled. For example, in a guess word there are two identical letters (letter a in the word award). The target word is brain. So, in the program the first letter a turns white (not yellow) and the second a turns green (because it is in the right spot).
  5. After printing the user's name a stopwatch starts and goes till the victory or last try.
  6. When the game is over, the user can copy guess disrtubution made with emoji.

Installation

It's recommended to first create a python virtual environment and then install the requirements with the following command:

pip3 install -r requirements.txt

Then run the command:

python project.py

Tech used

Python 3.10

Main files

  • project.py - main file with the game
  • test_project.py - three tests of the main program's functions
  • five-letter-words.txt - the list with 5-letter nouns.

Acknowledgments

I would like to express my deepest appreciation to David Malan and the whole CS50 team for entertaining lectures and helpful problem sets.

cs50p-final-project's People

Contributors

vasilisa-che 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.