GATE CSE
First time here? Checkout the FAQ!
x
0 votes
84 views

Consider a hash table with chaining scheme for overflow handling:

  1. What is the worst-case timing complexity of inserting $n$ elements into such a table?
  2. For what type of instance does this hashing scheme take the worst-case time for insertion?
asked in Algorithms by Veteran (30.4k points)  
edited by | 84 views

1 Answer

0 votes
1.) The worst case can be O(n) if all the insertions collide at the same key.

2.) This happens when we are not using an uniformly distributed hash function or when our hash table has only a single key where all the elements are chained up.
answered by (379 points)  


Top Users Jul 2017
  1. Bikram

    4910 Points

  2. manu00x

    2940 Points

  3. Debashish Deka

    1870 Points

  4. joshi_nitish

    1776 Points

  5. Arjun

    1506 Points

  6. Hemant Parihar

    1306 Points

  7. Shubhanshu

    1128 Points

  8. pawan kumarln

    1124 Points

  9. Arnab Bhadra

    1114 Points

  10. Ahwan

    956 Points


24,099 questions
31,074 answers
70,703 comments
29,407 users