A solution to the word chains ruby quiz