Why is answer 10 instead of 9:


#1

A : “baxug”
B : “clgko”
C : [ “cljkh”, “baxbg”, “bajbm”, “bljkm”, “baxug”, “cljko”, “bajbg”, “clnko”, “clgko”, “bljkh”, “bljbm” ]

The sequence should be :slight_smile:
next string is - baxbg
next string is - bajbg
next string is - bajbm
next string is - bljbm
next string is - bljkm
next string is - bljkh
next string is - cljkh
next string is - cljko
next string is - clgko


#2

because you are not considering beginWord (“baxug”) in total length;


#3

We need to count total number of steps and not the number of words in complete sequence.
baxug -> baxbg = step 1
baxbg -> bajbg = step 2

cljko -> clgko = step 9
Hence number of steps should be 9 instead of 10.


#4

If i am counting the first word as well in the no of steps, it is giving correct ans.
But according to the question we don’t have to consider the first word.