← All problemsSign in

Shortest transformation sequence

You are given two distinct words **startWord** and **targetWord**, and a denoting **wordList** of unique words of equal lengths. The size of **wordList** is **$N$**. Find the length of the shortest transformation sequence from **startWord** to **targetWord**. Keep the following conditions in mind: - A word can only consist of lowercase characters. - Only one letter can be changed in each transfo

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start