PHP round() Function

The round() function is used to rounds a number to the nearest integer.

Demo :



Type No :  
Round value is :0

Example :

Example 1: Type No: 0.60
Example 2: Type No: 0.49
Example 3: Type No: -5.60

If you need to calculate round value following code useful to you.


<?php
 $round_no = -10.89;
 $result = round($round_no);
 echo $result;
?>

In the above code is used to calculate for round the nearest integer whole value.In the round() functions have used two parameters that name is float number,[int precision].

Free Download Script :

If you need round() function demo code download from following link.

Download




Content