Skip to content

Instantly share code, notes, and snippets.

@xxsang
Created June 10, 2019 09:30
Show Gist options
  • Save xxsang/017b921c36c0bfa51c4c75d97592ff08 to your computer and use it in GitHub Desktop.
Save xxsang/017b921c36c0bfa51c4c75d97592ff08 to your computer and use it in GitHub Desktop.
Symbol Table Applications
1. Sets
1. A collection of distinct keys, no associated value
2. Symbol table without values
3. in or not in the list (whitelist blacklist)
1. spell checker, browser, parental controls, chess, spam filter, credit cards
2. Dictionary clients
3. Indexing clients
1. strings as sets
4. Sparse vector matrices
1. standard matrix(vector of vector) manipulation takes quadratic running time
2. sparse matrix (lot zeros) can use symbol table to represent to improve efficiency
1. key=index, value=entry
2. efficient iterator
3. space proportional to number of nonzeros
4. hash table
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment