Rewrite dictionary.searchWord

Rewrite with bisect algorithm and generator delegation syntax