Search⌘ K
AI Features

Solution: Word Ladder

Solution: Word Ladder asks for the shortest path from a source to a destination, changing one character per step with every later word drawn from a list. Return its length or zero if none exists.

Statement

Given two words, src and dest, and a list, words, return the number of words in the shortest transformation sequence from src to dest. If no such sequence could be formed, return 00.

A transformation sequence is a sequence of words ( ...