Changes

Jump to: navigation, search

JavaScript Math Object

133 bytes added, 14:13, 18 May 2007
Rounding and Truncating Numbers with the the Math Object
'''Math.round()''' - Rounds a number to the nearest integer (i.e up or down depending on which is closest)
 
Each of the above methods takes a number as an argument and returns the modified value:
 
<pre>
 
rounded = Math.round(8.87);
 
</pre>

Navigation menu