PHP round()


round(x) function returns the rounded value of x to the specified precision.

<?PHP
	echo round(3);  //3
	echo round(3.2);  //3
	echo round(3.5);  //4
?>

Specify the precision of the returned value.
<?PHP
   echo round(3.1415926, 2); //3.14
   echo round(3.1415926, 4); //3.1416  
?>