Skip to content

Sick of losing a wordle competition, I decided to code up this helper function to help me guess the best possible word.

Notifications You must be signed in to change notification settings

lachlanstephen/wordle-helper-C

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wordle Helper - C

This is a small C application I built to assist in making the most effective guesses in Wordle. This project was inspired by the sheer domination I was facing trying to compete with someone in the daily Wordle.

To run the Wordle helper:

  1. Run the command 'make re' (This creates the executable, compiling all necessary files)
  2. Run the executable ('./wordle-solver'), using the required arguments
  3. Repeat step 2, updating the arguments as you solve the Wordle further

For the executable to run, it requires 5 arguments0.

The arguments1 are as follows:

  1. Executable name ('./wordle-solver')
  2. Dictionary2 of words to use ('./dicts/answers\_wordle.txt')
  3. Current correct letters3 ('..a.e')
  4. Letters contained in answer, but not in correct spot ('t')
  5. Letters not contained in answer ('sl')

Example: ./wordle-solver ./dicts/answers\_wordle.txt '..a.e' 't' 'sl'

The above example would be the command run after the guess 'slate' was input into Wordle, when the answer is 'trace'

Notes:

  1. Please ensure all arguments are in lowercase, I haven't done any handling of uppercase letters
  2. The number out the front of the argument denotes the argument number in the program
  3. There are two dictionaries I provide to choose from pulled from NYTimes lists of valid answers and guesses. With a recent change to how they pick the word of the day, occassionally the answer is chosen from the valid guesses list. An example of this is 'Kazoo' which was the solution on the 19 June 2023. I always start with the answers dictionary, and if it doesn't show up, I move to the guesses dictionary.
  4. The current correct letters argument must have 5 characters! In the event you don't know the letter for that spot, you need to use the '.' character as a placeholder

As always, if you see any issues with my code or think I could improve it (whether it be in regards to time or space complexity, or anything at all), please let me know! (Probably by forking my repo and putting your own solution up with comments for me to see).

About

Sick of losing a wordle competition, I decided to code up this helper function to help me guess the best possible word.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published