MCPcopy Index your code
hub / github.com/coder/coder / Float64

Function Float64

cryptorand/numbers.go:63–66  ·  view source on GitHub ↗

Float64 returns a random number in [0.0,1.0) as a float64.

()

Source from the content-addressed store, hash-verified

61
62// Float64 returns a random number in [0.0,1.0) as a float64.
63func Float64() (float64, error) {
64 rng, cs := secureRand()
65 return rng.Float64(), cs.err
66}

Callers 3

genAgentMetricFunction · 0.92
TestRandErrorFunction · 0.92
TestFloat64Function · 0.92

Calls 1

secureRandFunction · 0.85

Tested by 3

genAgentMetricFunction · 0.74
TestRandErrorFunction · 0.74
TestFloat64Function · 0.74