Question

Hash tables are very useful in certain situations but they are not necessary in other situations....

Hash tables are very useful in certain situations but they are not necessary in other situations.

Discuss when you think a hash table should be used and when you think it should it be avoided.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Hash Table is a data structure that can map keys to values.Hash table is better than search trees or any other lookup structure.Hash table is mainly used in computer software as well as database indexing.It is generally used to implement associative arrays and dynamic resizing.Speed is one of the main advantage of Hash table.
Example : Pair Sum Problem, Sum of Functions Problem
Hash table is not used where we are not storing values at keys.The hash tables are not effective when the number of entries is very small,in that case we prefer array over hash tables.

Add a comment
Know the answer?
Add Answer to:
Hash tables are very useful in certain situations but they are not necessary in other situations....
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Dynamic perfect hash tables and cuckoo hash tables are two different data structures that support worst-case...

    Dynamic perfect hash tables and cuckoo hash tables are two different data structures that support worst-case O(1) lookups and expected O(1)-time insertions and deletions. Both require O(n) auxiliary space and access to families of hash functions for their operations. I think that both of these data structures are beautiful and brilliant in their own right, but I'm not sure I see how and when one of these would be preferable over the other. Are there specific contexts in which one...

  • Tables of data used to be very popular. Why do you think tables as a means...

    Tables of data used to be very popular. Why do you think tables as a means of storage and communicating standard data is less popular today? When would a table be an advantage over more advanced methods?

  • Hash Tables. (Hint: Diagrams might be helpful for parts a) and b). ) When inserting into...

    Hash Tables. (Hint: Diagrams might be helpful for parts a) and b). ) When inserting into hash table we insert at an index calculated by the key modulo the array size, what would happen if we instead did key mod (array_size*2), or key mod (array_size/2)? (Describe both cases). Theory answer Here Change your hashtable from the labs/assignments to be an array of linkedlists – so now insertion is done into a linkedlist at that index. Implement insertion and search. This...

  • C++ assignment - Hash table with linear probing --- implement in single file - main.cpp You...

    C++ assignment - Hash table with linear probing --- implement in single file - main.cpp You are asked to implement a very specific hash table. The keys are lower-case English words (e.g., apple, pear). The length of a key is at most 10. The hash function is “simply using the last character”. That is, the hash value of apple should be e, and the hash value of pear should be r. Your hash table contains exactly 26 slots (hash value...

  • This can be a very difficult issue for many people. Please discuss your reactions to the...

    This can be a very difficult issue for many people. Please discuss your reactions to the material presented this week. What do you believe is the best way to help someone involved in Domestic Violence and what do you think should be avoided. Please be sure to include some information from the readings and other material presented this week to back up your opinion.

  • think of some other "defined situations" for which unit standards of care might be useful. think...

    think of some other "defined situations" for which unit standards of care might be useful. think like a nurse suggest some other subgroups for which a protocol might be appropriate. fundamentals of nursing chapter 5 Knowledge Check 5-2 edition to care related to the patient's ces of information does a comprehensive care plan ents basic needs, what other types of informa contain? How are critical pathways different from ent from other standardized the main disadvantage of computerized and care plans?...

  • C++ Based upon the information provided on Hashing and Hash tables, create a Hash Table to...

    C++ Based upon the information provided on Hashing and Hash tables, create a Hash Table to store the data in the provided file which is a list of colors,ColorList.txt Using the basic algorithm that adds the ASCII values of each letter in the color and then mods by your chosen number of bins. Determine the best size (number of bins) for your hash table that is close to Balanced with an average list length between 12-15 (NOTE: list lengths of...

  • There are situations wherein a company faces a potential liability but is not certain of all...

    There are situations wherein a company faces a potential liability but is not certain of all the details associated with such potential liabilities What type of liabilities are these called? Discuss the guidelines for handling these types of liabilities. Do you agree with how these are handled? If yes, then why? If not, then what would you recommend FASB do differently? Should potential gains be treated identically to potential liabilities? Why or why not? Provide specific details to support your...

  • Discuss the importance of written contracts in certain situations - why do courts require these contracts be in writing? Choose one of the types of written contracts and discuss whether you think it&#...

    Discuss the importance of written contracts in certain situations - why do courts require these contracts be in writing? Choose one of the types of written contracts and discuss whether you think it's valid. Provide your own thoughts, as well as supporting sources from the internet. Provide a real-world or made up example to support your point.

  • Insert elements into a hash table implemented using chain hashing, as an array of linked list...

    Insert elements into a hash table implemented using chain hashing, as an array of linked list in which each entry slot is as a linked list of key/value pairings that have the same hash (outcome value computed using certain hash function). You are allowed to use “Hash Function”, h(k) = k % x where, x is the value you will need to decide to use, that you find appropriate for this implementation. The main requirements are the following: 1. Input:...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT