p ← s ##.birthday n                         ⍝ Probability of same birthday.

"In  a  group  of 23 people there is a better than 50-50 chance that two of them
 share a birthday".

This function from Nicolas Delcros and Roger Hui  generalises  this assertion to
find the probability of a pair of coincident results  occuring  from  n  trials,
each with probability ÷s.

See: http://www.jsoftware.com/jwiki/Essays/Birthday_Problem


    365 birthday 23       ⍝ probability that 2 people out of 23 share a birthday

    6 birthday 2          ⍝ probability of a pair in dice-throwing.

    (2*32) birthday 1e4   ⍝ probability of BuildID collision for 10.000 builds

Back to: contents

Back to: Workspaces