[HARD] Shortest word ladder - find the shortest path between two four letter words.
Using this list of words: (http://pastebin.com/zY4Xt7iB), input two four letter words and then output a word ladder between them that's as short as possible. Note that it only has to work for words that are on that list.
Example input:
look
leap
Example output:
look
loon
loan
lean
leap
[HARD] Shortest word ladder - find the shortest path between two four letter words.
Using this list of words: (http://pastebin.com/zY4Xt7iB), input two four letter words and then output a word ladder between them that's as short as possible. Note that it only has to work for words that are on that list.
Example input: look leap Example output: look loon loan lean leap