WORDLE, of course, refers to Josh Wardle's game (Wordle), but the observations below are probably applicable to the many clones that have appeared.
The standard elements are:
- DICT words: the dictionary, ie word list, the set of all 5 letter words that are allowed for any guess.
- GAME words: a subset (~20% of the DICT) of words that can be selected by the app as the code word (target word).
- Q1: What are the best word(s) to use for the initial guess?
- Q2: Would a 6-letter WORDLE be harder?
The approach is quite simple. Each game simulation involves fixing a target word, and one or two initial guess words, and then:
- tests the initial guess(es), obtaining a result code (Yellow, Green, Grey) (eg: [YXXGX])
- enters the guess loop:
- from the result codes identify the implied constraints implied (letters present, letters excluded, etc)
- find all words that satisfy these constraints
- select one at random as the next guess
- rinse-n-repeat until only one possibility remains
- GPW = average guesses per game
- total game score: 5 points for solved at guess #2, 4 points for guess #3, etc. No points for failure to solve in 6 guesses.
- weighted score: 16 points for solved at guess #2, 8 points for guess #3, 4 points for guess #4, etc.