Dictionary tries in Racket

For the next few posts, we’re going to need a way to represent a dictionary. You could go with just a flat list containing all of the words in the dictionary, but the runtime doesn’t seem optimal. Instead, we want a data structure that lets you easily get all possible words that start with a given prefix. We want a trie.

. Source: dictionary source code


Two Word Games

Another day, another post from Programming Praxis. Today they posted a word game that seems simple enough: first find all words in a given dictionary that contain all five vowels (a, e, i, o, u) in ascending order and then find any words (at least six letters long) where the letters are all in ascending alphabetical order.

read more...