0.0 can be generated; 1.0 cannot (since it is not within the range, therefore ) unlike [ ).
The probability of generating 0.0 is equal to the probability of generating any other number in this range, namely: 1 / X, where X is the number of different possible results. For a standard double-precision unsigned floating point, this usually means 53 bits of the fractional component, for 2 ^ 53 possible combinations, which leads to a probability of 1 / (2 ^ 53) generation exactly 0.0 .
So, although it is possible that it will return exactly 0.0 , it is unlikely that you will see this soon, but it is unlikely that you will see exactly any other value that you could choose in advance.
source share