Ch 18 (Carrano)
FOR THE ADT DICTIONARY a sorted array based implementation will need to shift data during what two operations?
ADDITIONS AND REMOVALS
For the ADT dictionary what implementation should you use when you do not know the maximum size of the dictionary? Link based, array based, heap based or binary search tree
BINARY SEARCH TREE
when two or more hash keys mapped two the same integer.
Collision
A sorted array based implementation of the dictionary cannot use a binary search
FALSE
The ADT dictionary should never allow duplicate search keys?
FALSE
What kind of function will tell you where a dictionary entry currently is or tell you where it will be placed for a new entry
Hash Function
When you begin at the hash location and have to search the dictionary sequentially
Linear Probing
The process of enlarging a hash table and computing new hash indices is referred to as doing what?
REHASHING
(t or f) To make an intelligent choice among all the dictionary implementations you have to analyze the efficiency with which each supports the dictionary operations
TRUE
A perfect hash function maps each search key into a unique location of the hash table
TRUE
Because linear implementations are easy to understand conceptually they are appropriate only for dictionaries that will contain small numbers of entries
TRUE
Double hashing drastically reduces clustering
TRUE
If the size of the problem is small the difference in efficiency between the different possible solutions is probably insignificant
TRUE
With link based dictionary implementation is a binary search practical?
TRUE
What is it called when you define a hash table so that each location in the hash table is itself an array, this is referred to as a_______
bucket
Dictionary has to store an association between the search key and the data value but only if its a sorted version not an unsorted
false
Quadratic probing causes no clustering
false
Quadratic requires more comparisons in probing than linear?
false
Hash functions are _____ date type
integer
What is the ADT used to identify entries?
key value pair or search key
Which one of these operations would not be something included in the operations on an ADT Dictionary: add new entry, retrieve an entry, sort the entry, or traverse in sorted search key order
sort the entry
A linear linked based implementation does not need to shift data for an add or remove operation
true
Binary search tree implementation of a dictionary is non linear
true
It is important that you know both the operations that are needed for a given application of a dictionary and how often each operation is required
true
The traverse method visits all the dictionary entries
true
With separate chaining the size of the dictionary is dynamic and can exceed the size of the hash table
true
the client code should not be able to modify an entries search key once that entry is actually in the dictionary
true
Questions about the ADT dictionary:appropriate for problems that must manage data by a)value b)order c)priority d)importance.
value