3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function ex_round($_,$__ = 1){ if(0== round($_, $__, PHP_ROUND_HALF_EVEN)){ return ex_round($_,$__+1) } return round($_, $__, PHP_ROUND_HALF_EVEN); } echo ex_round(0.005); echo PHP_EOL; echo round(0.005, 1, PHP_ROUND_HALF_ODD);
Output for 5.3.0 - 5.4.25
Parse error: syntax error, unexpected '}' in /in/gCiS2 on line 5
Process exited with code 255.