Question

1. Find the number of comparisons made by the sentinel version of sequential

search

a. in the worst case.

b. in the average case if the probability of a successful search is p (0 ≤ p ≤ 1).

Question image 1