Well, if you read the documentation you'll see that the probability of returning any particular float number is 1/2 to the power 53. So in your proposed variant, that would be the probability of returning 1. Basically your proposed variant is indistinguishable from the existing method; you would have to select 2 to the power 52 random numbers before you might expect to see 1 appear. It would take longer than your lifetime to do that.
In other words, you're wasting your time with this question.
> > Math.random()
also generate number
> from
> > 0 to 1 inclusive.
> >
> > but the chance to get 0 or 1, are very low.
>
> No!
>
> Math.random() also generates numbers less than 1 and
> each number has the exact same probability of being
> generated.
Yes, and that probability is so miniscule that the chances of getting 0 or 1 is very low. The chances of getting <insert any specific number> is very low.
> > > Math.random()
also generate number
> > from
> > > 0 to 1 inclusive.
> > >
> > > but the chance to get 0 or 1, are very low.
> >
> > No!
> >
> > Math.random() also generates numbers less than 1
> and
> > each number has the exact same probability of
> being
> > generated.
>
> Yes, and that probability is so miniscule that the
> chances of getting 0 or 1 is very low. The chances
> of getting <insert any specific number> is very low.
Point taken! I was assuming they meant relative to other numbers.