On the surface probability seems antithetical to the explicit well-defined determinism of programming.
On the surface probability seems antithetical to the explicit well-defined determinism of programming.
But if you modify the question to ask how likely it is for 3 people, or you add things like February 29th and leap years, or you add the fact that births are more likely during summer months, then it becomes extremely difficult to solve this deterministically. Instead, you run a Monte Carlo simulation to get approximate probabilities. This is much simpler to code and can be easily modified to fit new conditions.
A Monte Carlo simulation is probabilistic because you use random numbers in the simulation and you won't get a 100% perfect answer but you'll get close enough (and you can do some math to get error bounds).
Determinism is a nice illusion that quickly breaks down on real data. Scientific problems are non-unique and noise or inadequate models cause data and model to not mesh with one another. Deterministic answers have the property of being precisely wrong as opposed to mostly correct.
An HTTP library is good for making web calls. A probabilistic program is good for estimating probabilities.
One example would be polling. You could write down a program that estimates votes from political polls. Then feed it polling data and get estimates of how people will vote.
Also, randomized algorithms for all kinds of things are very useful in general-purpose computing