Trie's algorithm for implementing English word segmentation