Answer:
(A) since pmf is with replacement then the chance is given by ;
Pmf=X/n
(B) pmf without replacement is given by:
Pmf=X/(n-1)
Explanation:
Where x is the number of keys tried, n is the total number of keys.
Probability is given by : required outcome/total number of possible outcome