3v4l.org

run code in 300+ PHP versions simultaneously
<?php const EPSILON = 1e-8; $value = 4234568424.7199998; $rounded = round($value, 2); if (abs($rounded-$value) < EPSILON) { echo $rounded; } else { echo $value; }

preferences:
29.69 ms | 402 KiB | 5 Q