Words near half-open interval in the dictionary