round Method
Description
Rounds a supplied value to the nearest integer.Syntax
var numVar = Math.round( number )
Arguments
number: The value to be rounded to the nearest integer.
Return Value
If the decimal portion of number is .5 or greater, the return value is equal to the smallest integer greater than number. Otherwise, round returns the largest integer less than or equal to number.