3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $money = 100000000; $len = strlen($money); $m = ''; $money = strrev($money); for ($i = 0; $i < $len; $i++) { if (($i == 3 || ($i > 3 && ($i - 1) % 2 == 0)) && $i != $len) { $m .= ','; } $m .= $money[$i]; } $temp=strrev($m); echo $temp."00";
based on 3WaZO
Output for 5.6.30, hhvm-3.18.5 - 3.22.0, 7.0.30 - 7.3.0alpha1
10,00,00,00000