Chapter 9: Maps, Dictionaries, Hashing

Size: px
Start display at page:

Download "Chapter 9: Maps, Dictionaries, Hashing"

Transcription

1 Chapter 9: Maps, Dictionaries, Hashing Nancy Amato Parasol Lab, Dept. CSE, Texas A&M University Acknowledgement: These slides are adapted from slides provided with Data Structures and Algorithms in C++, Goodrich, Tamassia and Mount (Wiley 2004)

2 Outline and Reading Map ADT ( 9.1) Dictionary ADT ( 9.5) Ordered Maps ( 9.3) Hash Tables ( 9.2) Dictionaries 2

3 Map ADT The map ADT models a searchable collection of keyelement items The main operations of a map are searching, inserting, and deleting items Multiple items with the same key are not allowed Applications: address book credit card authorization mapping host names (e.g., cs16.net) to internet addresses (e.g., ) Map ADT methods: find(k): if M has an entry with key k, return an iterator p referring to this element, else, return special end iterator. put(k, v): if M has no entry with key k, then add entry (k, v) to M, otherwise replace the value of the entry with v; return iterator to the inserted/ modified entry erase(k) or erase(p): remove from M entry with key k or iterator p; An error occurs if there is no such element. size(), empty() Dictionaries 3

4 Map - Direct Address Table A direct address table is a map in which The keys are in the range {0,1,2,,N} Stored in an array of size N - T[0,N] Item with key k stored in T[k] Performance: insertitem, find, and removeelement all take O(1) time Space - requires space O(N), independent of n, the number of items stored in the map The direct address table is not space efficient unless the range of the keys is close to the number of elements to be stored in the map, I.e., unless n is close to N. Dictionaries 4

5 Dictionary ADT The dictionary ADT models a searchable collection of keyelement items The main difference from a map is that multiple items with the same key are allowed Any data structure that supports a dictionary also supports a map Applications: Dictionary which has multiple definitions for the same word Dictionary ADT methods: find(k): if the dictionary has an entry with key k, returns an iterator p to an arbitrary elt. findall(k): Return iterators (b,e) s.t. that all entries with key k are between them. insert(k, v): insert entry (k, v) into D, return iterator to it. erase(k), erase(p): remove arbitrary entry with key k or entry referenced by p. Error occurs if there is no such entry Begin(), end(): return iterator to first or just beyond last entry of D size(), isempty() Dictionaries Dictionaries & Hashing 5 3/27/14 10:04

6 Dictionary - Log File (unordered sequence implementation) A log file is a dictionary implemented by means of an unsorted sequence We store the items of the dictionary in a sequence (based on a doubly-linked lists or a circular array), in arbitrary order Performance: insert takes O(1) time since we can insert the new item at the beginning or at the end of the sequence find and erase take O(n) time since in the worst case (the item is not found) we traverse the entire sequence to look for an item with the given key Space - can be O(n), where n is the number of elements in the dictionary The log file is effective only for dictionaries of small size or for dictionaries on which insertions are the most common operations, while searches and removals are rarely performed (e.g., historical record of logins to a workstation) Dictionaries 6

7 Map/Dictionary implementations n - #elements in map/dictionary Insert Find Space Log File O(1) O(n) O(n) Direct Address Table (map only) O(1) O(1) O(N) Vectors 3/27/14 10:04 7

8 Ordered Map/Dictionary ADT An Ordered Map/Dictionary supports the usual map/ dictionary operations, but also maintains an order relation for the keys. Naturally supports Look-Up Tables - store dictionary in a vector by non-decreasing order of the keys Binary Search Ordered Map/Dictionary ADT: In addition to the generic map/ dictionary ADT, supports the following functions: closestbefore(k): return the position of an item with the largest key less than or equal to k closestafter(k): return the position of an item with the smallest key greater than or equal to k 3/27/14 10:04 8

9 Lookup Table A lookup table is a dictionary implemented by means of a sorted sequence We store the items of the dictionary in an array-based sequence, sorted by key We use an external comparator for the keys Performance: find takes O(log n) time, using binary search insertitem takes O(n) time since in the worst case we have to shift n/ 2 items to make room for the new item removeelement take O(n) time since in the worst case we have to shift n/2 items to compact the items after the removal The lookup table is effective only for dictionaries of small size or for dictionaries on which searches are the most common operations, while insertions and removals are rarely performed (e.g., credit card authorizations) 3/27/14 10:04 Dictionaries 9

10 Example of Ordered Map: Binary Search Binary search performs operation find(k) on a dictionary implemented by means of an array-based sequence, sorted by key similar to the high-low game at each step, the number of candidate items is halved terminates after a logarithmic number of steps Example: find(7) 0 l 0 l m h m h l m h l=m =h Dictionaries 3/27/14 10:04

11 Map/Dictionary implementations n - #elements in map/dictionary Insert Find Space Log File O(1) O(n) O(n) Direct Address Table (map only) Lookup Table (ordered map/dictionary) O(1) O(1) O(N) O(n) O(logn) O(n) Vectors 3/27/14 10:04 11

12 Hash Tables Hashing Hash table (an array) of size N, H[0,N] Hash function h that maps keys to indices in H Issues Hash functions - need method to transform key to an index in H that will have nice properties. Collisions - some keys will map to the same index of H (otherwise we have a Direct Address Table). Several methods to resolve the collisions Chaining - put elts that hash to same location in a linked list Open addressing - if a collision occurs, have a method to select another location in the table. Probe sequences Dictionaries 12

13 Hash Functions and Hash Tables A hash function h maps keys of a given type to integers in a fixed interval [0, N 1] Example: h(x) = x mod N is a hash function for integer keys The integer h(x) is called the hash value of key x A hash table for a given key type consists of Hash function h Array (called table) of size N When implementing a dictionary with a hash table, the goal is to store item (k, o) at index i = h(k) Dictionaries 13

14 Example We design a hash table for a dictionary storing items (SSN, Name), where SSN (social security number) is a nine-digit positive integer Our hash table uses an array of size N = 10,000 and the hash function h(x) = last four digits of x Dictionaries 14

15 Collisions Collisions occur when different elements are mapped to the same cell collisions must be resolved Chaining (store in list outside the table) Open addressing (store in another cell in the table) Example with Division Method h(k) = k mod N If N=10, then h(k)=0 for k=0,10,20, h(k)= 1 for k=1, 11, 21, etc Dictionaries 15

16 Collision Resolution with Chaining Collisions occur when different elements are mapped to the same cell Chaining: let each cell in the table point to a linked list of elements that map there Chaining is simple, but requires additional memory outside the table Dictionaries 16

17 Exercise: chaining Assume you have a hash table H with N=9 slots (H [0,8]) and let the hash function be h(k)=k mod N. Demonstrate (by picture) the insertion of the following keys into a hash table with collisions resolved by chaining. 5, 28, 19, 15, 20, 33, 12, 17, 10 Dictionaries 17

18 Collision Resolution in Open Addressing - Linear Probing Open addressing: the colliding item is placed in a different cell of the table Linear probing handles collisions by placing the colliding item in the next (circularly) available table cell. So the i-th cell checked is: H(k,i) = (h(k)+i)mod N Each table cell inspected is referred to as a probe Colliding items lump together, causing future collisions to cause a longer sequence of probes Example: h(x) = x mod 13 Insert keys 18, 41, 22, 44, 59, 32, 31, 73, in this order Dictionaries 18

19 Search with Linear Probing Consider a hash table A that uses linear probing find(k) We start at cell h(k) We probe consecutive locations until one of the following occurs An item with key k is found, or An empty cell is found, or N cells have been unsuccessfully probed Algorithm find(k) i h(k) p 0 repeat c A[i] if c = return Position(null) else if c.key () = k return Position(c) else i (i + 1) mod N p p + 1 until p = N return Position(null) Dictionaries 19

20 Updates with Linear Probing To handle insertions and deletions, we introduce a special object, called AVAILABLE, which replaces deleted elements removeelement(k) We search for an item with key k If such an item (k, o) is found, we replace it with the special item AVAILABLE and we return the position of this item Else, we return a null position insertitem(k, o) We throw an exception if the table is full We start at cell h(k) We probe consecutive cells until one of the following occurs A cell i is found that is either empty or stores AVAILABLE, or N cells have been unsuccessfully probed We store item (k, o) in cell i Dictionaries 20

21 Exercise: Linear Probing Assume you have a hash table H with N=11 slots (H [0,10]) and let the hash function be h(k)=k mod N. Demonstrate (by picture) the insertion of the following keys into a hash table with collisions resolved by linear probing. 10, 22, 31, 4, 15, 28, 17, 88, 59 Dictionaries 21

22 Open Addressing: Double Hashing Double hashing uses a secondary hash function h 2 (k) and handles collisions by placing an item in the first available cell of the series h(k,i) =(h 1 (k) + ih 2 (k)) mod N for i = 0, 1,, N 1 The secondary hash function h 2 (k) cannot have zero values The table size N must be a prime to allow probing of all the cells Common choice of compression map for the secondary hash function: h 2 (k) = q k mod q where q < N q is a prime The possible values for h 2 (k) are 1, 2,, q Dictionaries 22

23 Example of Double Hashing Consider a hash table storing integer keys that handles collision with double hashing N = 13 h 1 (k) = k mod 13 h 2 (k) = 7 k mod 7 Insert keys 18, 41, 22, 44, 59, 32, 31, 73, in this order Dictionaries 23

24 Exercise: Double Hashing Assume you have a hash table H with N=11 slots (H[0,10]) and let the hash functions for double hashing be h(k,i)=(h 1 (k) + ih 2 (k))mod N h 1 (k)=k mod N h 2 (k)=1 + (k mod (N-1)) Demonstrate (by picture) the insertion of the following keys into H 10, 22, 31, 4, 15, 28, 17, 88, 59 Dictionaries 24

25 Performance of Hashing In the worst case, searches, insertions and removals on a hash table take O(n) time The worst case occurs when all the keys inserted into the dictionary collide The load factor α = n/n affects the performance of a hash table Assuming that the hash values are like random numbers, it can be shown that the expected number of probes for an insertion with open addressing is 1 / (1 α) The expected running time of all the dictionary ADT operations in a hash table is O(1) In practice, hashing is very fast provided the load factor is not close to 100% Applications of hash tables: small databases compilers browser caches Dictionaries 29

26 Uniform Hashing Assumption The probe sequence of a key k is the sequence of slots that will be probed when looking for k In open addressing, the probe sequence is h(k,0), h(k,1), h(k,2), h (k,3), Uniform Hashing Assumption: Each key is equally likely to have any one of the N! permutations of {0,1, 2,, N-1} as is probe sequence Note: Linear probing and double hashing are far from achieving Uniform Hashing Linear probing: N distinct probe sequences Double Hashing: N 2 distinct probe sequences Dictionaries Dictionaries & Hashing 30 3/27/14 10:04

27 Performance of Uniform Hashing Theorem: Assuming uniform hashing and an openaddress hash table with load factor a = n/n < 1, the expected number of probes in an unsuccessful search is at most 1/(1-a). Exercise: compute the expected number of probes in an unsuccessful search in an open address hash table with a = ½, a=3/4, and a = 99/100. Dictionaries Dictionaries & Hashing 31 3/27/14 10:04

28 Universal Hashing A family of hash functions is universal if, for any 0<i,j<M-1, Pr(h(j)=h(i)) < 1/N. Choose p as a prime between M and 2M. Randomly select 0<a<p and 0<b<p, and define h(k)=(ak +b mod p) mod N Theorem: The set of all functions, h, as defined here, is universal. Dictionaries 32

29 Maps/Dictionaries n = #elements in map/dictionary, N=#possible keys (it could be N>>n) or size of hash table Insert Find Space Log File O(1) O(n) O(n) Direct Address Table (map only) Lookup Table (ordered map/dictionary) Hashing (chaining) O(1) O(1) O(N) O(n) O(logn) O(n) O(1) O(n/N) O(n+N) Hashing (open addressing) O(1/(1-n/N)) O(1/(1-n/N)) O(N) Vectors 3/27/14 10:04 35

CHAPTER 9 HASH TABLES, MAPS, AND SKIP LISTS

CHAPTER 9 HASH TABLES, MAPS, AND SKIP LISTS 0 1 2 025-612-0001 981-101-0002 3 4 451-229-0004 CHAPTER 9 HASH TABLES, MAPS, AND SKIP LISTS ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN C++, GOODRICH,

More information

Dictionaries and Hash Tables

Dictionaries and Hash Tables Dictionaries and Hash Tables 0 1 2 3 025-612-0001 981-101-0002 4 451-229-0004 Dictionaries and Hash Tables 1 Dictionary ADT The dictionary ADT models a searchable collection of keyelement items The main

More information

HASH TABLES. Goal is to store elements k,v at index i = h k

HASH TABLES. Goal is to store elements k,v at index i = h k CH 9.2 : HASH TABLES 1 ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN C++, GOODRICH, TAMASSIA AND MOUNT (WILEY 2004) AND SLIDES FROM JORY DENNY AND

More information

Dictionaries-Hashing. Textbook: Dictionaries ( 8.1) Hash Tables ( 8.2)

Dictionaries-Hashing. Textbook: Dictionaries ( 8.1) Hash Tables ( 8.2) Dictionaries-Hashing Textbook: Dictionaries ( 8.1) Hash Tables ( 8.2) Dictionary The dictionary ADT models a searchable collection of key-element entries The main operations of a dictionary are searching,

More information

Elementary Data Structures 2

Elementary Data Structures 2 Elementary Data Structures Priority Queues, & Dictionaries Priority Queues Sell 00 IBM $ Sell 300 IBM $0 Buy 00 IBM $9 Buy 400 IBM $8 Priority Queue ADT A priority queue stores a collection of items An

More information

CH 9 : MAPS AND DICTIONARIES

CH 9 : MAPS AND DICTIONARIES CH 9 : MAPS AND DICTIONARIES 1 ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN C++, GOODRICH, TAMASSIA AND MOUNT (WILEY 2004) AND SLIDES FROM JORY

More information

Dictionaries. 2/17/2006 Dictionaries 1

Dictionaries. 2/17/2006 Dictionaries 1 Dictionaries < 6 > 1 4 = 8 9 /17/006 Dictionaries 1 Outline and Reading Dictionary ADT ( 9.3) Log file ( 9.3.1) Binary search ( 9.3.3) Lookup table ( 9.3.3) Binary search tree ( 10.1) Search ( 10.1.1)

More information

Hash Tables Hash Tables Goodrich, Tamassia

Hash Tables Hash Tables Goodrich, Tamassia Hash Tables 0 1 2 3 4 025-612-0001 981-101-0002 451-229-0004 Hash Tables 1 Hash Functions and Hash Tables A hash function h maps keys of a given type to integers in a fixed interval [0, N 1] Example: h(x)

More information

Maps, Hash Tables and Dictionaries. Chapter 10.1, 10.2, 10.3, 10.5

Maps, Hash Tables and Dictionaries. Chapter 10.1, 10.2, 10.3, 10.5 Maps, Hash Tables and Dictionaries Chapter 10.1, 10.2, 10.3, 10.5 Outline Maps Hashing Dictionaries Ordered Maps & Dictionaries Outline Maps Hashing Dictionaries Ordered Maps & Dictionaries Maps A map

More information

This lecture. Iterators ( 5.4) Maps. Maps. The Map ADT ( 8.1) Comparison to java.util.map

This lecture. Iterators ( 5.4) Maps. Maps. The Map ADT ( 8.1) Comparison to java.util.map This lecture Iterators Hash tables Formal coursework Iterators ( 5.4) An iterator abstracts the process of scanning through a collection of elements Methods of the ObjectIterator ADT: object object() boolean

More information

Priority Queue Sorting

Priority Queue Sorting Priority Queue Sorting We can use a priority queue to sort a list of comparable elements 1. Insert the elements one by one with a series of insert operations 2. Remove the elements in sorted order with

More information

Data Structures Lecture 12

Data Structures Lecture 12 Fall 2017 Fang Yu Software Security Lab. Dept. Management Information Systems, National Chengchi University Data Structures Lecture 12 Advance ADTs Maps and Hash Tables Maps A map models a searchable collection

More information

CSED233: Data Structures (2017F) Lecture10:Hash Tables, Maps, and Skip Lists

CSED233: Data Structures (2017F) Lecture10:Hash Tables, Maps, and Skip Lists (2017F) Lecture10:Hash Tables, Maps, and Skip Lists Daijin Kim CSE, POSTECH dkim@postech.ac.kr Maps A map models a searchable collection of key-value entries The main operations of a map are for searching,

More information

Hash Tables. Johns Hopkins Department of Computer Science Course : Data Structures, Professor: Greg Hager

Hash Tables. Johns Hopkins Department of Computer Science Course : Data Structures, Professor: Greg Hager Hash Tables What is a Dictionary? Container class Stores key-element pairs Allows look-up (find) operation Allows insertion/removal of elements May be unordered or ordered Dictionary Keys Must support

More information

Chapter 10: Search Trees

Chapter 10: Search Trees < 6 > 1 4 = 8 9 Chapter 10: Search Trees Nancy Amato Parasol Lab, Dept. CSE, Texas A&M University Acknowledgement: These slides are adapted from slides provided with Data Structures and Algorithms in C++,

More information

CS2210 Data Structures and Algorithms

CS2210 Data Structures and Algorithms CS2210 Data Structures and Algorithms Lecture 5: Hash Tables Instructor: Olga Veksler 0 1 2 3 025-612-0001 981-101-0002 4 451-229-0004 2004 Goodrich, Tamassia Outline Hash Tables Motivation Hash functions

More information

Priority Queues and Heaps. More Data Structures. Priority Queue ADT ( 2.4.1) Total Order Relation. Sorting with a Priority Queue ( 2.4.

Priority Queues and Heaps. More Data Structures. Priority Queue ADT ( 2.4.1) Total Order Relation. Sorting with a Priority Queue ( 2.4. More Data Structures Priority Queues and Heaps Priority Queues, Comparators, Locators, Dictionaries More Data Structures v. More Data Structures v. Priority Queue ADT (.4.) Total Order Relation A priority

More information

Algorithms and Data Structures

Algorithms and Data Structures Lesson 4: Sets, Dictionaries and Hash Tables Luciano Bononi http://www.cs.unibo.it/~bononi/ (slide credits: these slides are a revised version of slides created by Dr. Gabriele D Angelo)

More information

CS 241 Analysis of Algorithms

CS 241 Analysis of Algorithms CS 241 Analysis of Algorithms Professor Eric Aaron Lecture T Th 9:00am Lecture Meeting Location: OLB 205 Business HW5 extended, due November 19 HW6 to be out Nov. 14, due November 26 Make-up lecture: Wed,

More information

Dictionary. Dictionary. stores key-value pairs. Find(k) Insert(k, v) Delete(k) List O(n) O(1) O(n) Sorted Array O(log n) O(n) O(n)

Dictionary. Dictionary. stores key-value pairs. Find(k) Insert(k, v) Delete(k) List O(n) O(1) O(n) Sorted Array O(log n) O(n) O(n) Hash-Tables Introduction Dictionary Dictionary stores key-value pairs Find(k) Insert(k, v) Delete(k) List O(n) O(1) O(n) Sorted Array O(log n) O(n) O(n) Balanced BST O(log n) O(log n) O(log n) Dictionary

More information

Hash Table. A hash function h maps keys of a given type into integers in a fixed interval [0,m-1]

Hash Table. A hash function h maps keys of a given type into integers in a fixed interval [0,m-1] Exercise # 8- Hash Tables Hash Tables Hash Function Uniform Hash Hash Table Direct Addressing A hash function h maps keys of a given type into integers in a fixed interval [0,m-1] 1 Pr h( key) i, where

More information

CSE100. Advanced Data Structures. Lecture 21. (Based on Paul Kube course materials)

CSE100. Advanced Data Structures. Lecture 21. (Based on Paul Kube course materials) CSE100 Advanced Data Structures Lecture 21 (Based on Paul Kube course materials) CSE 100 Collision resolution strategies: linear probing, double hashing, random hashing, separate chaining Hash table cost

More information

Open Addressing: Linear Probing (cont.)

Open Addressing: Linear Probing (cont.) Open Addressing: Linear Probing (cont.) Cons of Linear Probing () more complex insert, find, remove methods () primary clustering phenomenon items tend to cluster together in the bucket array, as clustering

More information

CSE 214 Computer Science II Searching

CSE 214 Computer Science II Searching CSE 214 Computer Science II Searching Fall 2017 Stony Brook University Instructor: Shebuti Rayana shebuti.rayana@stonybrook.edu http://www3.cs.stonybrook.edu/~cse214/sec02/ Introduction Searching in a

More information

CH 6 : VECTORS, LISTS AND SEQUENCES

CH 6 : VECTORS, LISTS AND SEQUENCES CH 6 : VECTORS, LISTS AND SEQUENCES ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN C++, GOODRICH, TAMASSIA AND MOUNT (WILEY 2004) AND SLIDES FROM

More information

1. [1 pt] What is the solution to the recurrence T(n) = 2T(n-1) + 1, T(1) = 1

1. [1 pt] What is the solution to the recurrence T(n) = 2T(n-1) + 1, T(1) = 1 Asymptotics, Recurrence and Basic Algorithms 1. [1 pt] What is the solution to the recurrence T(n) = 2T(n-1) + 1, T(1) = 1 2. O(n) 2. [1 pt] What is the solution to the recurrence T(n) = T(n/2) + n, T(1)

More information

Lecture 17. Improving open-addressing hashing. Brent s method. Ordered hashing CSE 100, UCSD: LEC 17. Page 1 of 19

Lecture 17. Improving open-addressing hashing. Brent s method. Ordered hashing CSE 100, UCSD: LEC 17. Page 1 of 19 Lecture 7 Improving open-addressing hashing Brent s method Ordered hashing Page of 9 Improving open addressing hashing Recall the average case unsuccessful and successful find time costs for common openaddressing

More information

Today s Outline. CS 561, Lecture 8. Direct Addressing Problem. Hash Tables. Hash Tables Trees. Jared Saia University of New Mexico

Today s Outline. CS 561, Lecture 8. Direct Addressing Problem. Hash Tables. Hash Tables Trees. Jared Saia University of New Mexico Today s Outline CS 561, Lecture 8 Jared Saia University of New Mexico Hash Tables Trees 1 Direct Addressing Problem Hash Tables If universe U is large, storing the array T may be impractical Also much

More information

Hash Tables Outline. Definition Hash functions Open hashing Closed hashing. Efficiency. collision resolution techniques. EECS 268 Programming II 1

Hash Tables Outline. Definition Hash functions Open hashing Closed hashing. Efficiency. collision resolution techniques. EECS 268 Programming II 1 Hash Tables Outline Definition Hash functions Open hashing Closed hashing collision resolution techniques Efficiency EECS 268 Programming II 1 Overview Implementation style for the Table ADT that is good

More information

Chapter 2: Basic Data Structures

Chapter 2: Basic Data Structures Chapter 2: Basic Data Structures Basic Data Structures Stacks Queues Vectors, Linked Lists Trees (Including Balanced Trees) Priority Queues and Heaps Dictionaries and Hash Tables Spring 2014 CS 315 2 Two

More information

Tirgul 7. Hash Tables. In a hash table, we allocate an array of size m, which is much smaller than U (the set of keys).

Tirgul 7. Hash Tables. In a hash table, we allocate an array of size m, which is much smaller than U (the set of keys). Tirgul 7 Find an efficient implementation of a dynamic collection of elements with unique keys Supported Operations: Insert, Search and Delete. The keys belong to a universal group of keys, U = {1... M}.

More information

Search Trees (Ch. 9) > = Binary Search Trees 1

Search Trees (Ch. 9) > = Binary Search Trees 1 Search Trees (Ch. 9) < 6 > = 1 4 8 9 Binary Search Trees 1 Ordered Dictionaries Keys are assumed to come from a total order. New operations: closestbefore(k) closestafter(k) Binary Search Trees Binary

More information

Practical Session 8- Hash Tables

Practical Session 8- Hash Tables Practical Session 8- Hash Tables Hash Function Uniform Hash Hash Table Direct Addressing A hash function h maps keys of a given type into integers in a fixed interval [0,m-1] 1 Pr h( key) i, where m is

More information

CH 6. VECTORS, LISTS, AND SEQUENCES

CH 6. VECTORS, LISTS, AND SEQUENCES CH 6. VECTORS, LISTS, AND SEQUENCES ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN C++, GOODRICH, TAMASSIA AND MOUNT (WILEY 2004) AND SLIDES FROM

More information

Lecture 4. Hashing Methods

Lecture 4. Hashing Methods Lecture 4 Hashing Methods 1 Lecture Content 1. Basics 2. Collision Resolution Methods 2.1 Linear Probing Method 2.2 Quadratic Probing Method 2.3 Double Hashing Method 2.4 Coalesced Chaining Method 2.5

More information

Lecture 7: Efficient Collections via Hashing

Lecture 7: Efficient Collections via Hashing Lecture 7: Efficient Collections via Hashing These slides include material originally prepared by Dr. Ron Cytron, Dr. Jeremy Buhler, and Dr. Steve Cole. 1 Announcements Lab 6 due Friday Lab 7 out tomorrow

More information

Advanced Algorithmics (6EAP) MTAT Hashing. Jaak Vilo 2016 Fall

Advanced Algorithmics (6EAP) MTAT Hashing. Jaak Vilo 2016 Fall Advanced Algorithmics (6EAP) MTAT.03.238 Hashing Jaak Vilo 2016 Fall Jaak Vilo 1 ADT asscociative array INSERT, SEARCH, DELETE An associative array (also associative container, map, mapping, dictionary,

More information

Hashing Techniques. Material based on slides by George Bebis

Hashing Techniques. Material based on slides by George Bebis Hashing Techniques Material based on slides by George Bebis https://www.cse.unr.edu/~bebis/cs477/lect/hashing.ppt The Search Problem Find items with keys matching a given search key Given an array A, containing

More information

CH 8. HEAPS AND PRIORITY QUEUES

CH 8. HEAPS AND PRIORITY QUEUES CH 8. HEAPS AND PRIORITY QUEUES ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN C++, GOODRICH, TAMASSIA AND MOUNT (WILEY 2004) AND SLIDES FROM NANCY

More information

CH. 8 PRIORITY QUEUES AND HEAPS

CH. 8 PRIORITY QUEUES AND HEAPS CH. 8 PRIORITY QUEUES AND HEAPS ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN C++, GOODRICH, TAMASSIA AND MOUNT (WILEY 2004) AND SLIDES FROM NANCY

More information

Quiz 1 Practice Problems

Quiz 1 Practice Problems Introduction to Algorithms: 6.006 Massachusetts Institute of Technology March 7, 2008 Professors Srini Devadas and Erik Demaine Handout 6 1 Asymptotic Notation Quiz 1 Practice Problems Decide whether these

More information

Hashing. Manolis Koubarakis. Data Structures and Programming Techniques

Hashing. Manolis Koubarakis. Data Structures and Programming Techniques Hashing Manolis Koubarakis 1 The Symbol Table ADT A symbol table T is an abstract storage that contains table entries that are either empty or are pairs of the form (K, I) where K is a key and I is some

More information

1/18/12. Chapter 5: Stacks, Queues and Deques. Stacks. Outline and Reading. Nancy Amato Parasol Lab, Dept. CSE, Texas A&M University

1/18/12. Chapter 5: Stacks, Queues and Deques. Stacks. Outline and Reading. Nancy Amato Parasol Lab, Dept. CSE, Texas A&M University Chapter 5: Stacks, ueues and Deques Nancy Amato Parasol Lab, Dept. CSE, Texas A&M University Acknowledgement: These slides are adapted from slides provided with Data Structures and Algorithms in C++, Goodrich,

More information

Introduction. hashing performs basic operations, such as insertion, better than other ADTs we ve seen so far

Introduction. hashing performs basic operations, such as insertion, better than other ADTs we ve seen so far Chapter 5 Hashing 2 Introduction hashing performs basic operations, such as insertion, deletion, and finds in average time better than other ADTs we ve seen so far 3 Hashing a hash table is merely an hashing

More information

Quiz 1 Practice Problems

Quiz 1 Practice Problems Introduction to Algorithms: 6.006 Massachusetts Institute of Technology March 7, 2008 Professors Srini Devadas and Erik Demaine Handout 6 1 Asymptotic Notation Quiz 1 Practice Problems Decide whether these

More information

DataStruct 9. Hash Tables, Maps, Skip Lists, and Dictionaries

DataStruct 9. Hash Tables, Maps, Skip Lists, and Dictionaries 2013-2 DataStruct 9. Hash Tables, Maps, Skip Lists, and Dictionaries Michael T. Goodrich, et. al, Data Structures and Algorithms in C++, 2 nd Ed., John Wiley & Sons, Inc., 2011. November 22, 2013 Advanced

More information

Hashing. Hashing Procedures

Hashing. Hashing Procedures Hashing Hashing Procedures Let us denote the set of all possible key values (i.e., the universe of keys) used in a dictionary application by U. Suppose an application requires a dictionary in which elements

More information

Binary Search Trees (10.1) Dictionary ADT (9.5.1)

Binary Search Trees (10.1) Dictionary ADT (9.5.1) Binary Search Trees (10.1) CSE 011 Winter 011 4 March 011 1 Dictionary ADT (..1) The dictionary ADT models a searchable collection of keyelement items The main operations of a dictionary are searching,

More information

CH 6 : VECTORS, LISTS AND SEQUENCES

CH 6 : VECTORS, LISTS AND SEQUENCES CH 6 : VECTORS, LISTS AND SEQUENCES ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN C++, GOODRICH, TAMASSIA AND MOUNT (WILEY 2004) AND SLIDES FROM

More information

COMP171. Hashing.

COMP171. Hashing. COMP171 Hashing Hashing 2 Hashing Again, a (dynamic) set of elements in which we do search, insert, and delete Linear ones: lists, stacks, queues, Nonlinear ones: trees, graphs (relations between elements

More information

DATA STRUCTURES AND ALGORITHMS

DATA STRUCTURES AND ALGORITHMS LECTURE 11 Babeş - Bolyai University Computer Science and Mathematics Faculty 2017-2018 In Lecture 9-10... Hash tables ADT Stack ADT Queue ADT Deque ADT Priority Queue Hash tables Today Hash tables 1 Hash

More information

Introducing Hashing. Chapter 21. Copyright 2012 by Pearson Education, Inc. All rights reserved

Introducing Hashing. Chapter 21. Copyright 2012 by Pearson Education, Inc. All rights reserved Introducing Hashing Chapter 21 Contents What Is Hashing? Hash Functions Computing Hash Codes Compressing a Hash Code into an Index for the Hash Table A demo of hashing (after) ARRAY insert hash index =

More information

Algorithms and Data Structures

Algorithms and Data Structures Ordered Dictionaries and Binary Search Trees Page 1 BFH-TI: Softwareschule Schweiz Ordered Dictionaries and Binary Search Trees Dr. CAS SD01 Ordered Dictionaries and Binary Search Trees Page Outline Ordered

More information

Module 2: Classical Algorithm Design Techniques

Module 2: Classical Algorithm Design Techniques Module 2: Classical Algorithm Design Techniques Dr. Natarajan Meghanathan Associate Professor of Computer Science Jackson State University Jackson, MS 39217 E-mail: natarajan.meghanathan@jsums.edu Module

More information

CS 350 : Data Structures Hash Tables

CS 350 : Data Structures Hash Tables CS 350 : Data Structures Hash Tables David Babcock (courtesy of James Moscola) Department of Physical Sciences York College of Pennsylvania James Moscola Hash Tables Although the various tree structures

More information

Table ADT and Sorting. Algorithm topics continuing (or reviewing?) CS 24 curriculum

Table ADT and Sorting. Algorithm topics continuing (or reviewing?) CS 24 curriculum Table ADT and Sorting Algorithm topics continuing (or reviewing?) CS 24 curriculum A table ADT (a.k.a. Dictionary, Map) Table public interface: // Put information in the table, and a unique key to identify

More information

Week 9. Hash tables. 1 Generalising arrays. 2 Direct addressing. 3 Hashing in general. 4 Hashing through chaining. 5 Hash functions.

Week 9. Hash tables. 1 Generalising arrays. 2 Direct addressing. 3 Hashing in general. 4 Hashing through chaining. 5 Hash functions. Week 9 tables 1 2 3 ing in ing in ing 4 ing 5 6 General remarks We continue data structures by discussing hash tables. For this year, we only consider the first four sections (not sections and ). Only

More information

Final Exam. EECS 2011 Prof. J. Elder - 1 -

Final Exam. EECS 2011 Prof. J. Elder - 1 - Final Exam Ø Wed Apr 11 2pm 5pm Aviva Tennis Centre Ø Closed Book Ø Format similar to midterm Ø Will cover whole course, with emphasis on material after midterm (maps and hash tables, binary search, loop

More information

Topic HashTable and Table ADT

Topic HashTable and Table ADT Topic HashTable and Table ADT Hashing, Hash Function & Hashtable Search, Insertion & Deletion of elements based on Keys So far, By comparing keys! Linear data structures Non-linear data structures Time

More information

csci 210: Data Structures Maps and Hash Tables

csci 210: Data Structures Maps and Hash Tables csci 210: Data Structures Maps and Hash Tables Summary Topics the Map ADT Map vs Dictionary implementation of Map: hash tables READING: GT textbook chapter 9.1 and 9.2 Map ADT A Map is an abstract data

More information

Understand how to deal with collisions

Understand how to deal with collisions Understand the basic structure of a hash table and its associated hash function Understand what makes a good (and a bad) hash function Understand how to deal with collisions Open addressing Separate chaining

More information

Data Structures and Algorithm Analysis (CSC317) Hash tables (part2)

Data Structures and Algorithm Analysis (CSC317) Hash tables (part2) Data Structures and Algorithm Analysis (CSC317) Hash tables (part2) Hash table We have elements with key and satellite data Operations performed: Insert, Delete, Search/lookup We don t maintain order information

More information

Fast Lookup: Hash tables

Fast Lookup: Hash tables CSE 100: HASHING Operations: Find (key based look up) Insert Delete Fast Lookup: Hash tables Consider the 2-sum problem: Given an unsorted array of N integers, find all pairs of elements that sum to a

More information

CSE 332: Data Structures & Parallelism Lecture 10:Hashing. Ruth Anderson Autumn 2018

CSE 332: Data Structures & Parallelism Lecture 10:Hashing. Ruth Anderson Autumn 2018 CSE 332: Data Structures & Parallelism Lecture 10:Hashing Ruth Anderson Autumn 2018 Today Dictionaries Hashing 10/19/2018 2 Motivating Hash Tables For dictionary with n key/value pairs insert find delete

More information

of characters from an alphabet, then, the hash function could be:

of characters from an alphabet, then, the hash function could be: Module 7: Hashing Dr. Natarajan Meghanathan Professor of Computer Science Jackson State University Jackson, MS 39217 E-mail: natarajan.meghanathan@jsums.edu Hashing A very efficient method for implementing

More information

HashTable CISC5835, Computer Algorithms CIS, Fordham Univ. Instructor: X. Zhang Fall 2018

HashTable CISC5835, Computer Algorithms CIS, Fordham Univ. Instructor: X. Zhang Fall 2018 HashTable CISC5835, Computer Algorithms CIS, Fordham Univ. Instructor: X. Zhang Fall 2018 Acknowledgement The set of slides have used materials from the following resources Slides for textbook by Dr. Y.

More information

Stores a collection of elements each with an associated key value

Stores a collection of elements each with an associated key value CH9. PRIORITY QUEUES ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH DATA STRUCTURES AND ALGORITHMS IN JAVA, GOODRICH, TAMASSIA AND GOLDWASSER (WILEY 201) PRIORITY QUEUES Stores a collection

More information

Topics on the Midterm

Topics on the Midterm Midterm Review Topics on the Midterm Data Structures & Object-Oriented Design Run-Time Analysis Linear Data Structures The Java Collections Framework Recursion Trees Priority Queues & Heaps Maps, Hash

More information

Data Structures and Algorithms. Chapter 7. Hashing

Data Structures and Algorithms. Chapter 7. Hashing 1 Data Structures and Algorithms Chapter 7 Werner Nutt 2 Acknowledgments The course follows the book Introduction to Algorithms, by Cormen, Leiserson, Rivest and Stein, MIT Press [CLRST]. Many examples

More information

CS 270 Algorithms. Oliver Kullmann. Generalising arrays. Direct addressing. Hashing in general. Hashing through chaining. Reading from CLRS for week 7

CS 270 Algorithms. Oliver Kullmann. Generalising arrays. Direct addressing. Hashing in general. Hashing through chaining. Reading from CLRS for week 7 Week 9 General remarks tables 1 2 3 We continue data structures by discussing hash tables. Reading from CLRS for week 7 1 Chapter 11, Sections 11.1, 11.2, 11.3. 4 5 6 Recall: Dictionaries Applications

More information

University of Toronto Department of Electrical and Computer Engineering. Midterm Examination. ECE 345 Algorithms and Data Structures Fall 2012

University of Toronto Department of Electrical and Computer Engineering. Midterm Examination. ECE 345 Algorithms and Data Structures Fall 2012 1 University of Toronto Department of Electrical and Computer Engineering Midterm Examination ECE 345 Algorithms and Data Structures Fall 2012 Print your name and ID number neatly in the space provided

More information

Worst-case running time for RANDOMIZED-SELECT

Worst-case running time for RANDOMIZED-SELECT Worst-case running time for RANDOMIZED-SELECT is ), even to nd the minimum The algorithm has a linear expected running time, though, and because it is randomized, no particular input elicits the worst-case

More information

Lecture 16. Reading: Weiss Ch. 5 CSE 100, UCSD: LEC 16. Page 1 of 40

Lecture 16. Reading: Weiss Ch. 5 CSE 100, UCSD: LEC 16. Page 1 of 40 Lecture 16 Hashing Hash table and hash function design Hash functions for integers and strings Collision resolution strategies: linear probing, double hashing, random hashing, separate chaining Hash table

More information

Acknowledgement HashTable CISC4080, Computer Algorithms CIS, Fordham Univ.

Acknowledgement HashTable CISC4080, Computer Algorithms CIS, Fordham Univ. Acknowledgement HashTable CISC4080, Computer Algorithms CIS, Fordham Univ. Instructor: X. Zhang Spring 2018 The set of slides have used materials from the following resources Slides for textbook by Dr.

More information

Module 5: Hashing. CS Data Structures and Data Management. Reza Dorrigiv, Daniel Roche. School of Computer Science, University of Waterloo

Module 5: Hashing. CS Data Structures and Data Management. Reza Dorrigiv, Daniel Roche. School of Computer Science, University of Waterloo Module 5: Hashing CS 240 - Data Structures and Data Management Reza Dorrigiv, Daniel Roche School of Computer Science, University of Waterloo Winter 2010 Reza Dorrigiv, Daniel Roche (CS, UW) CS240 - Module

More information

(D) There is a constant value n 0 1 such that B is faster than A for every input of size. n n 0.

(D) There is a constant value n 0 1 such that B is faster than A for every input of size. n n 0. Part : Multiple Choice Enter your answers on the Scantron sheet. We will not mark answers that have been entered on this sheet. Each multiple choice question is worth. marks. Note. when you are asked to

More information

Hashing. Dr. Ronaldo Menezes Hugo Serrano. Ronaldo Menezes, Florida Tech

Hashing. Dr. Ronaldo Menezes Hugo Serrano. Ronaldo Menezes, Florida Tech Hashing Dr. Ronaldo Menezes Hugo Serrano Agenda Motivation Prehash Hashing Hash Functions Collisions Separate Chaining Open Addressing Motivation Hash Table Its one of the most important data structures

More information

Today: Finish up hashing Sorted Dictionary ADT: Binary search, divide-and-conquer Recursive function and recurrence relation

Today: Finish up hashing Sorted Dictionary ADT: Binary search, divide-and-conquer Recursive function and recurrence relation Announcements HW1 PAST DUE HW2 online: 7 questions, 60 points Nat l Inst visit Thu, ok? Last time: Continued PA1 Walk Through Dictionary ADT: Unsorted Hashing Today: Finish up hashing Sorted Dictionary

More information

Hash Open Indexing. Data Structures and Algorithms CSE 373 SP 18 - KASEY CHAMPION 1

Hash Open Indexing. Data Structures and Algorithms CSE 373 SP 18 - KASEY CHAMPION 1 Hash Open Indexing Data Structures and Algorithms CSE 373 SP 18 - KASEY CHAMPION 1 Warm Up Consider a StringDictionary using separate chaining with an internal capacity of 10. Assume our buckets are implemented

More information

Binary Search Trees > = 2014 Goodrich, Tamassia, Goldwasser. Binary Search Trees 1

Binary Search Trees > = 2014 Goodrich, Tamassia, Goldwasser. Binary Search Trees 1 Binary Search Trees < > = Binary Search Trees 1 Ordered Dictionary (Map) ADT get (k): record with key k put (k,data): add record (k,data) remove (k): delete record with key k smallest(): record with smallest

More information

University of Waterloo Department of Electrical and Computer Engineering ECE250 Algorithms and Data Structures Fall 2014

University of Waterloo Department of Electrical and Computer Engineering ECE250 Algorithms and Data Structures Fall 2014 University of Waterloo Department of Electrical and Computer Engineering ECE250 Algorithms and Data Structures Fall 2014 Midterm Examination Instructor: Ladan Tahvildari, PhD, PEng, SMIEEE Date: Tuesday,

More information

Unit #5: Hash Functions and the Pigeonhole Principle

Unit #5: Hash Functions and the Pigeonhole Principle Unit #5: Hash Functions and the Pigeonhole Principle CPSC 221: Basic Algorithms and Data Structures Jan Manuch 217S1: May June 217 Unit Outline Constant-Time Dictionaries? Hash Table Outline Hash Functions

More information

CSE 332 Winter 2015: Midterm Exam (closed book, closed notes, no calculators)

CSE 332 Winter 2015: Midterm Exam (closed book, closed notes, no calculators) _ UWNetID: Lecture Section: A CSE 332 Winter 2015: Midterm Exam (closed book, closed notes, no calculators) Instructions: Read the directions for each question carefully before answering. We will give

More information

CMSC 341 Lecture 16/17 Hashing, Parts 1 & 2

CMSC 341 Lecture 16/17 Hashing, Parts 1 & 2 CMSC 341 Lecture 16/17 Hashing, Parts 1 & 2 Prof. John Park Based on slides from previous iterations of this course Today s Topics Overview Uses and motivations of hash tables Major concerns with hash

More information

Data Structures And Algorithms

Data Structures And Algorithms Data Structures And Algorithms Hashing Eng. Anis Nazer First Semester 2017-2018 Searching Search: find if a key exists in a given set Searching algorithms: linear (sequential) search binary search Search

More information

CS1020 Data Structures and Algorithms I Lecture Note #15. Hashing. For efficient look-up in a table

CS1020 Data Structures and Algorithms I Lecture Note #15. Hashing. For efficient look-up in a table CS1020 Data Structures and Algorithms I Lecture Note #15 Hashing For efficient look-up in a table Objectives 1 To understand how hashing is used to accelerate table lookup 2 To study the issue of collision

More information

Hash Tables. Reading: Cormen et al, Sections 11.1 and 11.2

Hash Tables. Reading: Cormen et al, Sections 11.1 and 11.2 COMP3600/6466 Algorithms 2018 Lecture 10 1 Hash Tables Reading: Cormen et al, Sections 11.1 and 11.2 Many applications require a dynamic set that supports only the dictionary operations Insert, Search

More information

Hashing. October 19, CMPE 250 Hashing October 19, / 25

Hashing. October 19, CMPE 250 Hashing October 19, / 25 Hashing October 19, 2016 CMPE 250 Hashing October 19, 2016 1 / 25 Dictionary ADT Data structure with just three basic operations: finditem (i): find item with key (identifier) i insert (i): insert i into

More information

III Data Structures. Dynamic sets

III Data Structures. Dynamic sets III Data Structures Elementary Data Structures Hash Tables Binary Search Trees Red-Black Trees Dynamic sets Sets are fundamental to computer science Algorithms may require several different types of operations

More information

Data Structures and Algorithms. Roberto Sebastiani

Data Structures and Algorithms. Roberto Sebastiani Data Structures and Algorithms Roberto Sebastiani roberto.sebastiani@disi.unitn.it http://www.disi.unitn.it/~rseba - Week 07 - B.S. In Applied Computer Science Free University of Bozen/Bolzano academic

More information

Hashing. Yufei Tao. Department of Computer Science and Engineering Chinese University of Hong Kong

Hashing. Yufei Tao. Department of Computer Science and Engineering Chinese University of Hong Kong Department of Computer Science and Engineering Chinese University of Hong Kong In this lecture, we will revisit the dictionary search problem, where we want to locate an integer v in a set of size n or

More information

Readings. Priority Queue ADT. FindMin Problem. Priority Queues & Binary Heaps. List implementation of a Priority Queue

Readings. Priority Queue ADT. FindMin Problem. Priority Queues & Binary Heaps. List implementation of a Priority Queue Readings Priority Queues & Binary Heaps Chapter Section.-. CSE Data Structures Winter 00 Binary Heaps FindMin Problem Quickly find the smallest (or highest priority) item in a set Applications: Operating

More information

Hashing Algorithms. Hash functions Separate Chaining Linear Probing Double Hashing

Hashing Algorithms. Hash functions Separate Chaining Linear Probing Double Hashing Hashing Algorithms Hash functions Separate Chaining Linear Probing Double Hashing Symbol-Table ADT Records with keys (priorities) basic operations insert search create test if empty destroy copy generic

More information

5. Hashing. 5.1 General Idea. 5.2 Hash Function. 5.3 Separate Chaining. 5.4 Open Addressing. 5.5 Rehashing. 5.6 Extendible Hashing. 5.

5. Hashing. 5.1 General Idea. 5.2 Hash Function. 5.3 Separate Chaining. 5.4 Open Addressing. 5.5 Rehashing. 5.6 Extendible Hashing. 5. 5. Hashing 5.1 General Idea 5.2 Hash Function 5.3 Separate Chaining 5.4 Open Addressing 5.5 Rehashing 5.6 Extendible Hashing Malek Mouhoub, CS340 Fall 2004 1 5. Hashing Sequential access : O(n). Binary

More information

CMSC 341 Hashing (Continued) Based on slides from previous iterations of this course

CMSC 341 Hashing (Continued) Based on slides from previous iterations of this course CMSC 341 Hashing (Continued) Based on slides from previous iterations of this course Today s Topics Review Uses and motivations of hash tables Major concerns with hash tables Properties Hash function Hash

More information

Standard ADTs. Lecture 19 CS2110 Summer 2009

Standard ADTs. Lecture 19 CS2110 Summer 2009 Standard ADTs Lecture 19 CS2110 Summer 2009 Past Java Collections Framework How to use a few interfaces and implementations of abstract data types: Collection List Set Iterator Comparable Comparator 2

More information

Hashing. Introduction to Data Structures Kyuseok Shim SoEECS, SNU.

Hashing. Introduction to Data Structures Kyuseok Shim SoEECS, SNU. Hashing Introduction to Data Structures Kyuseok Shim SoEECS, SNU. 1 8.1 INTRODUCTION Binary search tree (Chapter 5) GET, INSERT, DELETE O(n) Balanced binary search tree (Chapter 10) GET, INSERT, DELETE

More information

Chapter 5 Hashing. Introduction. Hashing. Hashing Functions. hashing performs basic operations, such as insertion,

Chapter 5 Hashing. Introduction. Hashing. Hashing Functions. hashing performs basic operations, such as insertion, Introduction Chapter 5 Hashing hashing performs basic operations, such as insertion, deletion, and finds in average time 2 Hashing a hash table is merely an of some fixed size hashing converts into locations

More information

CSC263 Week 5. Larry Zhang.

CSC263 Week 5. Larry Zhang. CSC263 Week 5 Larry Zhang http://goo.gl/forms/s9yie3597b Announcements PS3 marks out, class average 81.3% Assignment 1 due next week. Response to feedbacks -- tutorials We spent too much time on working

More information

The dictionary problem

The dictionary problem 6 Hashing The dictionary problem Different approaches to the dictionary problem: previously: Structuring the set of currently stored keys: lists, trees, graphs,... structuring the complete universe of

More information