3v4l.org

run code in 500+ PHP versions simultaneously
<?php $f = '0'; for($i=0; $i < 10000; $i++) { $f = bcadd($f, '0.01', 2); } var_dump($f);
Output for 8.0.1 - 8.0.30, 8.1.0 - 8.1.34, 8.2.0 - 8.2.34, 8.3.0 - 8.3.35, 8.4.1 - 8.4.26, 8.5.0
string(6) "100.00"
Output for 8.5.1 - 8.5.11
Fatal error: Uncaught Error: Call to undefined function bcadd() in /in/V3gn9:6 Stack trace: #0 {main} thrown in /in/V3gn9 on line 6
Process exited with code 255.

preferences:
31.13 ms | 1139 KiB | 9 Q