7.0 Introduction

7.1 Symbol Attributes

7.2 Symbol Table Operations

7.3 External Data Structures

7.4 Internal Data Structures

7.5 Other Symbol Table Techniques

7.6 Summary

Web References

Exercises

External Data Structures for Symbol
Tables

By External Data Structure, we mean the data structure used to represent the Symbol "Table". Internal Data structures will represent the various parts (how the names and attributes will be stored.

A symbol table makes a wonderful data structure example since the pros and cons for the various data structures can be easily explored.

Notice, first of all, that a name is entered once, but may be retrieved many times. In fact, even the enter operation may be preceded by a lookup operation to ascertain that the symbol is not already there. Thus, data structures which search rapidly are to be preferred when efficiency is an issue.

Some data structures make it easier to implement block structure information.

We will consider a number of options using this program as an example:

An Unordered List

An Ordered List

A Binary Tree

A Hash Table

Other Structures

Send questions and comments to: Karen Lemone