//Here is the code pertaining to the problem...
var mRN = function getRandom()
{
return Math.random()*10
};
/*Code works just fine, when I call on it it returns a random
number.
Now my question, mRN will acquire a new random number
for every time it is called upon.. here is the next part of the code:
*/
document.write(mRN());
document.write("
Rounding:
");
document.write(Math.round(mRN()));
*/How do I make mRN return the same value to line 1 and 3 above so I can put what the number in line 1 is when rounded?
Thanks
*/
2007-04-25
09:24:51
·
2 answers
·
asked by
Simba
4