3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $v = 111111; $t = 0; while($v){ $g = (int) $v / 10; $n = $g * 10; $d = $v - $n; $v = $g; $t += $d; } echo $t;
based on rKf4l
Output for 4.3.0 - 7.2.0
0.60000000000027