5.2-2 What is the probability that you hire exactly twice

Problem:

In HIRE-ASSISTANT, assuming that the candidates are presented in a random order, what is the probability that you hire exactly twice?


Anlysis

Observation 1: You have to hire the first person interviewed because the assumed number 0 condidate is the worst.

Then the answer is: what's the probability that you have hired one person x with rank(x) and have to hire another condidate?

Observation 2: If rank(x) = n, then the conditional probability will be 0;

Observation 3: if rank(x)=n-1, the the conditional probalibity will be 1;

Observatoin 4: if rank(x)=n-2, then the conditional probability will be ?

....

if rank(x) = rx, then the maximum condidates of all the condidates with rank > rx, ie n, must come before other condidates with rank>rx.

permutate all the remaining condidates P(all) = (n-1)!  C(target) = P(all)/P(n-rx)*P(n-rx-1) = (n-1)!/(n-rx)!*(n-rx-1)! = (n-1)!/(n-rx), p(target) = c(target)/P(n-1)=1/(n-rx);

Then add up all the numbers above each multipied by the probability of the condition.

1/n * E{ 1 / (n-rx) } (rx:1 ~ n-1);


Optimized method for calculating the conditional probability for each case above:

the case is as follows: we have (n-1) condidates left,  order of (n-rx) must be ordered that the n will be the first of the (n-rx) condidates. Assume that we have arrived at a situation where all other condidates has been put in a position, we have to position the (n-rx) condidates one by one with equal probability so that the order we randomly put the (n-rx) condidates will not matter, so we just put the critical rank n condidates first, what's the probability of he/she be put in the first of the left (n-rx) positions? Of course it's 1/(n-rx);

The final result is 1 / n * E{ 1 / (n-rx) } (rx:1 ~ n-1);  The same as the above.




评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值