主页
PHP
PHP 数字
tryphp_numbers_cast
运行 ❯
×
更改方向
保存代码
更改主题
<?php // Cast float to int $x = 23465.768; $int_cast = (int)$x; echo $int_cast; echo "
"; // Cast string to int $x = "23465.768"; $int_cast = (int)$x; echo $int_cast; ?>
23465
23465