Update README.md

This commit is contained in:
marina 2023-08-02 18:42:48 -07:00 committed by GitHub
parent fd5bbaee8d
commit fb7059d0e6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,15 +3,23 @@
<br>
* tries, also called prefix tree, are a variant of n-ary tree in which characters are stored in each node.
* each trie node represents a string (a prefix) and each path down the tree represents a word. note that not all the strings represented by trie nodes are meaningful.
* the root is associated with the empty string.
* the * nodes (null nodes) are often used to indicate complete words (usually represented by a special type of child) or a boolean flag that terminates the parent node.
* a node can have anywhere from 1 through alphabet_size + 1 child.
* can be used to store the entire english language for quick prefix lookup (O(k), where k is the length of the string). they are also widely used on autocompletes, spell checkers, and ip routing (longest prefix matching).
* tries structures can be represented by arrays and maps or trees.
<br>
----
### insertion
<br>
@ -21,6 +29,9 @@
<br>
---
### search
<br>