PeterO.RandomGenerator.Geometric C# (CSharp) Метод

Geometric() публичный Метод

Conceptually, generates either 1 or 0 until a 1 is generated, and counts the number of 0's generated. Either number has an equal probability of being generated.
public Geometric ( ) : int
Результат int
        public int Geometric()
        {
            return this.NegativeBinomial(1, 0.5);
        }

Same methods

RandomGenerator::Geometric ( double p ) : int