code: func (beng BernoulliGenerator) Bernoulli_P(p float64) bool {
  	if !(0.0 <= p && p <= 1.0) {
  		panic(fmt.Sprintf("Invalid probability: %.2f", p))
  	}
  	return beng.uniform.Float64() < p
  }
docs: // Bernoulli_P returns a bool, which is true with probablity p