nextBool()
Generates and returns a new random Boolean value.
Declaration
func nextBool() -> BoolReturn Value
A random Boolean value.
Discussion
Typically, custom classes implementing this protocol should implement the nextBool() method based on the value returned by the nextInt(upperBound:) method. Alternative implementations are possible, but may lead to less uniform results.