Given an array of strings
wordsDictand two different strings that already exist in the arrayword1andword2, return the shortest distance between these two words in the list.
1 | class Solution { |
Given an array of strings
wordsDictand two different strings that already exist in the arrayword1andword2, return the shortest distance between these two words in the list.
1 | class Solution { |