Probability theory quantifies uncertainty about possible outcomes. A probability is a number from zero to one: zero represents an outcome never observed, while one represents certainty. The same mathematics supports two interpretations: frequentism treats probability as long-run observed frequency, while Bayesian reasoning treats it as confidence informed by available evidence. section 12.1
A coin toss before a game
Suppose Red has a 50% chance of winning a pregame coin toss and a 70% chance of defeating Blue if Red wins it. A frequentist interpretation asks about repeated trials; a Bayesian interpretation treats 70% as a confidence level that could justify a $70 bet on a $100 payout. Bayesian probabilities change when new evidence arrives. section 12.1
Probability supports a higher-level approach to randomness and statistical inference:
- Represent random quantities as distributions rather than relying only on standard random-number-generating functions. section 12.0
- Manipulate distributions with sequence-oriented operations such as Where, SelectMany, Join, and GroupBy. section 12.0
- Use probability as groundwork for applying Bayes’ theorem when new real-world evidence must inform a decision. section 12.0
- Implement probabilistic tools from scratch in C#, with the ideas intended to transfer to other mainstream object-oriented languages. section 1.3















