Dictionary Coding Checkpoint

Worked scenarios: trace state, diagnose mistakes, and apply the module contract.


Get every question correct to pass this checkpoint. You can review feedback, revise your answers, and submit again.

1. The output is Q. Decode a match of distance 1 and length 4. Give the final text.
2. At one position, matches of length 5 occur at distances 3 and 8; a length 4 match occurs at distance 1. Which token is required?

Select one answer.

3. A fresh LZW decoder reads [88,256]. What ASCII text results?
4. LZW previous phrase is BA, nextCode is 270, and the stream contains unknown code 271. Does KwKwK justify it?

Select one answer.

5. With window=0, how many LZ77 tokens encode five bytes AAAAA?
6. The encoder freezes its LZW dictionary at 4096 entries while the decoder resets to 256. What fails?

Select one answer.

Join Discord