410 Design and Analysis of Algorithms
15.3 COMPLEXITY OF SET OPERATIONS AND MAPPINGS
A recurring theme in computer problem solving is the need to deal with various kinds of sets and mappings.
Frequently, the need arises for sets of integers, strings, and more complex data types, as well as mappings
from a wide variety of types to integers, and so on. Thus it is worthwhile using these in our discussion of
complexity. A wide variety of different representations for these abstractions is available and they differ in
the types of data they handle, the complexity, space requirements, and coding diffi culty.
Thinking of a set as a class, the following operations are typical:
fi nd Find out whether a member is in the set. If so, return a locator for ...