The Probability Density/Mass Function (PDF/PMF).
Returns the probability of the distribution at x.
x
@override double probability(int k) => 0 <= k && k <= n ? combination(n, k) * pow(p, k) * pow(q, n - k) : 0;