Question

In: Computer Science

DEPTH counting starts at 1 at the root. What should the loading factor be (on ANY...

DEPTH counting starts at 1 at the root.

What should the loading factor be (on ANY HASH TABLE) if you want to have an average of 1.4 comparisons per successful search if LINEAR PROBING?

Solutions

Expert Solution

Required average number of comparisons per successful search = 1.4

We know in linear probing, average number of comparisons = (1/2) (1 + (1/(1 - )))

Where, = loading factor

average number of comparisons = (1/2) * (1 + (1/(1 - )))

or, 1.4 = (1/2) * (1 + (1/(1 - )))

or, 1.4 = (1/2) * ((1 * (1 - ) + 1)/(1 - ))

or, 1.4 = (1/2) * ((1 - + 1) / (1 - ))

or, 2.8 = (2 - ) / (1 - )

or, 2 - = 2.8 - 2.8

or, 1.8 = 2.8 - 2

or, 1.8 = 0.8

or, = 0.444

So, the loading factor for the hash table = 0.444.

Please comment in case of any doubt.
Please upvote if this helps.


Related Solutions

DEPTH counting starts at 1 at the root. Q1 [20 pts.]: Given the following key sequence...
DEPTH counting starts at 1 at the root. Q1 [20 pts.]: Given the following key sequence (6,22,9,14,13,1,8) build the dynamic binary search tree WITHOUT BALANCING IT. How many probes (i.e., comparisons) does it take to determine that key 100 is not in the tree? (In this study case, the root is 6; the next element 22 > 6, so it goes to the right, etc).
DEPTH counting starts at 1 at the root. How many total nodes does a 7-ary tree...
DEPTH counting starts at 1 at the root. How many total nodes does a 7-ary tree have if its depth is 8? Hash the given file (6,22,9,14,13,1,8) and use linear probing and the table size of 11. How many total collisions occurred? What is the loading density of the table?
A portfolio has a market beta of 0.8, a factor loading of 1 to SMB and...
A portfolio has a market beta of 0.8, a factor loading of 1 to SMB and a sensitivity of -2 to HML. The portfolio has earned 16% return. What was the abnormal return on the portfolio, if the risk free rate was 0%, market's excess return was 8%, the SMB factor premium was -10% and the HML factor premium was -4%? 22% 16.2% 4.4% 11.6%
A portfolio has a market beta of 0.8, a factor loading of 1 to SMB and...
A portfolio has a market beta of 0.8, a factor loading of 1 to SMB and a sensitivity of -2 to HML. The portfolio has earned 16% return. What was the abnormal return on the portfolio, if the risk free rate was 0%, market's excess return was 8%, the SMB factor premium was -10% and the HML factor premium was -4%? 22% 16.2% 4.4% 11.6%
In any design of hydraulic structures, a safety factor should be included. Describe what a safety...
In any design of hydraulic structures, a safety factor should be included. Describe what a safety factor is and why it is crucial in the design. This question is open-ended. Therefore it must be supported by relevant literature.
1.-Define the combustor loading parameter. Why is the exponential factor different to ideal scenario?
1.-Define the combustor loading parameter. Why is the exponential factor different to ideal scenario?
Where does the square root of (1+1/n) factor come from in the prediction interval? A tolerance...
Where does the square root of (1+1/n) factor come from in the prediction interval? A tolerance interval includes two percentage values. What do the two percentage values represent?
Each student should write a page and a half about any factor that contributing in decreasing...
Each student should write a page and a half about any factor that contributing in decreasing or increasing the cost of healthcare. The factors contributing to decrease in costs is: value-based purchasing management of physician preference in medical devices. The factors contributing to increase in costs is: emerging medical technology chronic disease
what are the pharmokinetics factor of fluoxetine any two with explanation please
what are the pharmokinetics factor of fluoxetine any two with explanation please
The binary number system uses just two digits (0 and 1) to represent any counting number....
The binary number system uses just two digits (0 and 1) to represent any counting number. Match each of the familiar 'base-10' numbers below with their 8-digit binary equivalents. Group of answer choices 7       [ Choose ]            00001111            01000001            00001101            00001000       8       [ Choose ]            00001111            01000001            00001101            00001000   ...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT