can someone explain me,what is the difference between radix tree and suffix tree??
# | User | Rating |
---|---|---|
1 | tourist | 4009 |
2 | jiangly | 3823 |
3 | Benq | 3738 |
4 | Radewoosh | 3633 |
5 | jqdai0815 | 3620 |
6 | orzdevinwang | 3529 |
7 | ecnerwala | 3446 |
8 | Um_nik | 3396 |
9 | ksun48 | 3390 |
10 | gamegame | 3386 |
# | User | Contrib. |
---|---|---|
1 | cry | 165 |
2 | maomao90 | 163 |
2 | Um_nik | 163 |
4 | atcoder_official | 161 |
5 | adamant | 160 |
6 | -is-this-fft- | 158 |
7 | awoo | 157 |
8 | TheScrasse | 154 |
9 | nor | 153 |
9 | Dominater069 | 153 |
Name |
---|
A Trie is just a simple structure that you build from a list of words to support efficient O(w) querying/retrieval. 'w' being the length of the query.
A Radix tree is a compressed Trie such that every node necessarily has branching. All paths that look like a linked list are compressed into a single node. Use a Trie or a compressed Trie when you want to build a hash table where the keys will be strings (usually having an upper bound on their length). A Suffix Tree is also a compressed suffix-trie except that it is built on a single string instead of on an array of strings, and given the property of a compressed suffix trie that we saw above, there can be at most O(n) nodes, where 'n' is the number of characters in the string.