conditional probability of knowledge given a correct selection among n alternatives. Exercise from Pfeiffer
Looks good.
$$P(B|A)=\frac{P(B)P(A|B)}{P(A)}=\frac{P(B)P(A|B)}{P(B)P(A|B) + P(B^C)P(A|B^C)}=\frac{p\cdot 1}{p\cdot 1 +(1-p)\frac1n }=\frac{p}{p+\frac{1-p}n}$$