(12pts) The mathematics main office has backup keys to the offices in Kiely Hall. One day Dr. Unlucky locked himself out of his office. So he borrowed the keys from the main office. Unfortunately, these keys have no room number on them and thus he has to try one by one. Suppose there are n keys and only one key will open Dr. Unlucky’s office. (a) (6pts) If he tries the keys at random and discards those that do not work, what is the probability that he will open the door on his k-th (k = 1, 2, ..., n) try? (b) (6pts) What if he does not discard previously tried keys?
a) If he discard previously tried keys
Prob(Opening the door at kth key) =
(here x will start from 0 and will go till (k-1).
The first term is calculating the probability of k-1 keys to be wrong, and then the second term is calculating the probability of kth key to be right. So multiplying both we calculate the overall probability of opening the door at kth key.
b) If he doesn't discard previously used keys
Prob(Opening the door at kth key) = ((n-1)/n)k-1*(1/n)
The first term here too is calculating the probability of k-1 keys to be wrong, and then the second term is calculating the probability of kth key to be right. So multiplying both we calculate the overall probability of opening the door at kth key.
Please upvote if this helps.
Get Answers For Free
Most questions answered within 1 hours.