Questions and Answers
Which operation is used to add an element to a hash table?
Insertion
What is the purpose of the search operation in a hash table?
To look-up values
How does the hash function resolve collisions in a hash table?
By assigning a new index number
What does the delete operation do in a hash table?
Signup and view all the answers
In the given Python example, what is the value of the hash key for 3?
Signup and view all the answers
What is the purpose of the hash_key function in the Python example?
Signup and view all the answers
What is the value of the hash key for 9 in the given Python example?
Signup and view all the answers
What is the purpose of the m parameter in the hash_key function?
Signup and view all the answers
Which data structure is commonly used to store and access data easily and efficiently?
Signup and view all the answers
What is the time complexity for searching in an Array data structure?
Signup and view all the answers
Why was there a need for a new data structure even though Array was already available?
Signup and view all the answers
What is the purpose of a hash function in hashing?
Signup and view all the answers
What is a collision in hashing?
Signup and view all the answers
What is one advantage of hashing in data structures?
Signup and view all the answers
What does a hash table do in hashing?
Signup and view all the answers
What is the time complexity for searching in a hash table?
Signup and view all the answers
What is one application of hashing?
Signup and view all the answers
Which data structure is an example of a hash table?
Signup and view all the answers
What is the time complexity of hash tables in the best-case scenario?
Signup and view all the answers
What happens when two values generate the same hash key in a hash table?
Signup and view all the answers
What is the disadvantage of using hash tables?
Signup and view all the answers
What is the process of generating a fixed-size output from an input of variable size using mathematical formulas called?
Signup and view all the answers
What is the average time complexity of hash tables?
Signup and view all the answers
What is the purpose of chaining in hash tables?
Signup and view all the answers
What is the advantage of using hash tables?
Signup and view all the answers
Studying That Suits You
Use AI to generate personalized quizzes and flashcards to suit your learning preferences.