题目
题目

2025W Quiz 5 (copy)

单项选择题

Which of the following is true about deleting a key-value pair from a hash table that uses separate chaining to resolve collisions?

选项
A.a. Deleting from the hash table can be done with simple linked-list node deletion, and no rehashing is required.
B.b. After deletion, only the keys after the given node must be rehashed.
C.c. After deletion, all keys must be rehashed.
D.d. Deleting can take O(N^2)-time in the worst case when there are N elements in the hash table.
查看解析

查看解析

标准答案
Please login to view
思路分析
The question asks about deleting a key-value pair from a hash table that uses separate chaining for collision resolution. Option A: 'Deleting from the hash table can be done with simple linked-list node deletion, and no rehashing is required.' In a separate chaining scheme, each bucket contains a linked list of entries. To delete a specific key, you locate the appropriate bucket and remove the node from its linked list by upd......Login to view full explanation

登录即可查看完整答案

我们收录了全球超50000道考试原题与详细解析,现在登录,立即获得答案。

类似问题

更多留学生实用工具

加入我们,立即解锁 海量真题独家解析,让复习快人一步!