3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $val = 8/16; $fr = 10; $to = 16; if (strcmp($val, base_convert($val, $fr, $fr) )) { echo "$val isn't purely in base $fr"; } else { $newval = base_convert($val, $fr, $to); echo "new val is $newval"; } echo pow(5,10,-1);
Output for 5.2.3 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
0.5 isn't purely in base 10 Warning: pow() expects exactly 2 parameters, 3 given in /in/pRE8E on line 12
Output for 4.3.0 - 5.2.2
0.5 isn't purely in base 10<br /> <b>Warning</b>: pow() expects exactly 2 parameters, 3 given in <b>/in/pRE8E</b> on line <b>12</b><br />