Returns the quantile (inverse CDF) for the given probability p as an Int.
Return
the smallest outcome k in {0, 1} such that cdf(k) >= p. Returns 0 when p <= 1 - probability (including the boundary), and 1 otherwise.
the cumulative probability, must be in [0, 1].