Probability of 100 cells in array

An array stores 100 keys. Given that the unit cost of comparing a key with a search
key is c, determine the expected cost of searching the array for the following cases:
(i) There is equal probability of finding the search key in any of the cells.
(ii) There is 70% chance that the key is in the first 50 cells and 30% chance that the
search key is in the next 50 cells.
(iii) There is 80% chance that the key is in the array, and 20% chance that the key is
not in the array.
Asked Jul 07, 2013

If you are looking for a place to share your travel photos and stories, then try BigRoom.

TIP: If it's not your answer to this question, please click "Leave a Comment" button under the question to communicate with the question owner.