jeudi 7 mai 2015

How can I randomly generate a number between the range -0.5 and 0.5?

In javascript how do I randomly generate a number between -0.5 and 0.5? The following only seems to give positive numbers, and no negative numbers.

Math.random(-0.15, 0.15)




Aucun commentaire:

Enregistrer un commentaire