Java ThreadLocalRandom nextGaussian() method

The nextGaussian() method of Java ThreadLocalRandom class returns the next pseudorandom which is the Gaussian ("normally") distributed double value with mean 0.0 and standard deviation 1.0 from this random number generator's sequence.

Syntax:

Parameter:

NA

Returns:

This method returns the next pseudorandom which is the Gaussian distributed double value.

Example 1

Output:

Random Gaussian double value is: 0.44227562722507735