Outline for December 1, 2025

Reading: none
Assignments: Homework 5/Project, due December 8, 2025

  1. Write program to help solve Wordle
    1. Sketch out goals, inputs and outputs, and approach
    2. Implement it step-by-step

  2. Step 1: read word list [wordle-1.py]

  3. Step 2: eliminate words that are not exactly 5 characters long [wordle-2.py]

  4. Step 3: read pattern, characters that must be in the word (“good letters”), characters that are not in the word (“bad letters”) [wordle-3.py]
    1. Step 3a: check no letters are both good and bad [wordle-3a.py]

  5. Step 4: eliminate words containing bad letters [wordle-4.py]
    1. Step 4a: make all letters lower case [wordle-4a.py]

  6. Step 5: Eliminate words with no good letters [wordle-5.py]

  7. Step 6. Eliminate words that do not match a pattern [wordle-6.py]

  8. Step 7. If word list named on command line, use it [wordle-7.py]

  9. Step 8. Now clean up the code [wordle-8.py]
    1. Empty pattern causes error; check for it
    2. Check for invalid patterns *before* asking for other inputs
    3. Eliminate printing pattern, and good and bad letters

UC Davis sigil
Matt Bishop
Office: 2209 Watershed Sciences
Phone: +1 (530) 752-8060
Email: mabishop@ucdavis.edu
MHI 289I, Programming in Health Informatics
Version of December 2, 2025 at 10:28AM

You can also obtain a PDF version of this.

Valid HTML 4.01 Transitional Built with BBEdit Built on a Macintosh