add ned's word_chains solution