pub fn closest<'a>( word: &str, candidates: impl IntoIterator<Item = &'a str>, ) -> Option<&'a str>
The candidate closest to word, if it’s close enough to be a plausible typo.
word