Pergunta de entrevista da empresa Hearst

Code ngrams. Given an array of correct words, match input string to the correct word in the array. ex. "hnda" -> "honda"