Ceil: Calculates the smallest integer greater than the specified number.
Floor: Calculates the largest integer less than the specified number.
round: Rounded.
Choose
Copy code as needed. The code is as follows:
$a=20;
$b = 6;
echo ($a/$b)."
"; //out 3.3333333333333
echo ceil($a/$b). "
"; //out 4
echo floor($a/$b)."
"; //out 3
echo round($a/$b)."< ;br>"; //out 3
?>
http://www.bkjia.com/PHPjc/327518.htmlwww.bkjia.comtruehttp: //www.bkjia.com/PHPjc/327518.htmlTechArticleCeil: Calculate the smallest integer greater than the specified number. Floor: Computes the largest integer less than the specified number. round: rounded. Copy the code as needed. The code is as follows: ?php $a=20; $b = 6...