Fixed a minor issue in WordLadder.

Change-Id: I6c2346979efff1bb40101a00ed7bb27f0f2fc7cb