NAMES:

LOGINS:

PRECEPTS:

COS 226 Exercises on Tries

References: Section 5.2 in Algorithms, 4th edition

1. Draw the R-way trie when you insert the following key-value pairs into an initially empty trie. Use the alphabet of ten digits (R = 10). Draw all of the null links.

351-A  652-B  893-C  353-D  352-E  622-F  3522-G  355-H



















2. Draw the TST that results when you insert the following keys into an initially empty trie (in the order given). Draw all of the null links.

351-A  652-B  893-C  353-D  352-E  622-F  3522-G  355-H